Assertion in LegacyWebArchive::create() in editing tests
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-03-20  Ryosuke Niwa  <rniwa@webkit.org>
2
3         Assertion in LegacyWebArchive::create() in editing tests
4         https://bugs.webkit.org/show_bug.cgi?id=112642
5
6         Reviewed by Simon Fraser.
7
8         Address Simon's review comment. Don't convert String to MIMEType just to convert it back to String.
9
10         * platform/mac/PasteboardMac.mm:
11         (WebCore::fragmentFromWebArchive):
12
13 2013-03-20  Zan Dobersek  <zdobersek@igalia.com>
14
15         [GTK] Build ANGLE sources into a separate library from libWebCore.la
16         https://bugs.webkit.org/show_bug.cgi?id=112778
17
18         Reviewed by Martin Robinson.
19
20         No new tests - no change in functionality.
21
22         * GNUmakefile.list.am: Remove the ANGLE sources listing, it's now placed in the ANGLE-specific GNUmakefile.am.
23
24 2011-03-20  Ryosuke Niwa  <rniwa@webkit.org>
25
26         Assertion in LegacyWebArchive::create() in editing tests
27         https://bugs.webkit.org/show_bug.cgi?id=112642
28
29         Reviewed by Enrica Casucci.
30
31         It's possible for clipboard to be overriden between the time we retrieve clipboard types and the time
32         we actually retrieve the Web archive buffer. Add a null check to take this into account.
33
34         Also extracted fragmentFromWebArchive for clarity.
35
36         * platform/mac/PasteboardMac.mm:
37         (WebCore::fragmentFromWebArchive): Extracted.
38         (WebCore::Pasteboard::documentFragment):
39
40 2013-03-20  Chris Fleizach  <cfleizach@apple.com>
41
42         WebSpeech: Crash in WebCore::PlatformSpeechSynthesisUtterance::client / WebCore::SpeechSynthesis::didResumeSpeaking
43         https://bugs.webkit.org/show_bug.cgi?id=112728
44
45         Reviewed by Tim Horton.
46
47         When cancel() is called, there was a delay in the platform returning and saying speech was finished, which caused
48         the m_currentSpeechUtterance variable to get deallocated but not cleared. 
49
50         This patch fixes up the management of the utterances in SpeechSynthesis and the Mac platform given that
51         we can't rely on the platform to return immediately on a stop speaking job.
52
53         Test: platform/mac/fast/speechsynthesis/speech-synthesis-cancel-crash.html
54
55         * Modules/speech/SpeechSynthesis.cpp:
56         (WebCore::SpeechSynthesis::cancel):
57         (WebCore::SpeechSynthesis::resume):
58         * platform/mac/PlatformSpeechSynthesizerMac.mm:
59         (-[WebSpeechSynthesisWrapper cancel]):
60         (-[WebSpeechSynthesisWrapper speechSynthesizer:didFinishSpeaking:]):
61         (-[WebSpeechSynthesisWrapper speechSynthesizer:willSpeakWord:ofString:]):
62
63 2013-03-20  Eric Carlson  <eric.carlson@apple.com>
64
65         Unreviewed, fix Mac release build.
66
67         * page/CaptionUserPreferencesMac.mm:
68         (WebCore::languageIdentifier):
69
70 2013-03-20  Eric Carlson  <eric.carlson@apple.com>
71
72         Allow ports specific text track menu
73         https://bugs.webkit.org/show_bug.cgi?id=112800
74
75         Reviewed by Dean Jackson.
76
77         No new tests, existing tests updated for changes.
78
79         * English.lproj/Localizable.strings: Add localizable strings for text track names.
80
81         * html/HTMLMediaElement.cpp:
82         (WebCore::HTMLMediaElement::HTMLMediaElement): userPrefersCaptions -> shouldShowCaptions.
83         (WebCore::HTMLMediaElement::setSelectedTextTrack): toggleTrackAtIndex -> setSelectedTextTrack.
84         (WebCore::HTMLMediaElement::userPrefersCaptions): userPrefersCaptions -> shouldShowCaptions.
85         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Get preferences from CaptionUserPreferences
86             instead of from Settings.
87         (WebCore::HTMLMediaElement::setSelectedTextTrack): Renamed from toggleTrackAtIndex. Now takes
88             a TextTrack* instead of an int.
89         (WebCore::HTMLMediaElement::captionPreferencesChanged): Don't force a recalculation unless 
90             captions are enabled/disabled to avoid unnecessary thrash.
91         * html/HTMLMediaElement.h:
92
93         * html/shadow/MediaControlElements.cpp:
94         (WebCore::MediaControlClosedCaptionsTrackListElement::defaultEventHandler): Use the menu to track
95             map instead of just the track index.
96         (WebCore::MediaControlClosedCaptionsTrackListElement::updateDisplay): Build and configure the
97             menu from the menu to track map.
98         (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu): Start with a list
99             of tracks already sorted according to platform specific rules. Build a menu to track map
100             so tracks are retained while the menu is visible.
101         * html/shadow/MediaControlElements.h:
102
103         * html/shadow/MediaControls.cpp:
104         (WebCore::MediaControls::textTrackPreferencesChanged): Call closedCaptionTracksChanged so the
105             track menu will be rebuilt before it is shown again.
106
107         * html/track/InbandTextTrack.cpp:
108         (WebCore::InbandTextTrack::containsOnlyForcedSubtitles): New, passthrough to the private track.
109         (WebCore::InbandTextTrack::isMainProgramContent): Ditto.
110         (WebCore::InbandTextTrack::isEasyToRead): Ditto.
111         * html/track/InbandTextTrack.h:
112         * html/track/TextTrack.h:
113
114         * html/track/TextTrackList.cpp:
115         (WebCore::TextTrackList::contains): New.
116         * html/track/TextTrackList.h:
117
118         * page/CaptionUserPreferences.cpp:
119         (WebCore::CaptionUserPreferences::CaptionUserPreferences): Pull in from .h ditto.
120         (WebCore::CaptionUserPreferences::~CaptionUserPreferences): Ditto.
121         (WebCore::CaptionUserPreferences::shouldShowCaptions): Renamed from userPrefersCaptions. 
122         (WebCore::CaptionUserPreferences::setShouldShowCaptions): New.
123         (WebCore::CaptionUserPreferences::userPrefersCaptions): Ditto.
124         (WebCore::CaptionUserPreferences::setUserPrefersCaptions): Ditto.
125         (WebCore::CaptionUserPreferences::userPrefersSubtitles): Ditto.
126         (WebCore::CaptionUserPreferences::setUserPrefersSubtitles): Ditto.
127         (WebCore::CaptionUserPreferences::userPrefersTextDescriptions): Ditto.
128         (WebCore::CaptionUserPreferences::setUserPrefersTextDescriptions): Ditto.
129         (WebCore::CaptionUserPreferences::displayNameForTrack): Ditto.
130         (WebCore::CaptionUserPreferences::sortedTrackListForMenu): Ditto.
131         * page/CaptionUserPreferences.h:
132
133         * page/CaptionUserPreferencesMac.h:
134         * page/CaptionUserPreferencesMac.mm:
135         (WebCore::CaptionUserPreferencesMac::shouldShowCaptions): Renamed from userPrefersCaptions. 
136         (WebCore::CaptionUserPreferencesMac::userPrefersCaptions): New.
137         (WebCore::CaptionUserPreferences::userPrefersSubtitles): Ditto.
138         (WebCore::trackDisplayName): Update logic used to build track title.
139         (WebCore::CaptionUserPreferencesMac::displayNameForTrack): Call trackDisplayName.
140         (WebCore::textTrackCompare): Text track title sort comparison function.
141         (WebCore::CaptionUserPreferencesMac::sortedTrackListForMenu): New. Sort the list of tracks
142             according to title, language, and user preferences.
143
144         * platform/Language.cpp:
145         (WebCore::displayNameForLanguageLocale): Don't leak the CFLocale.
146         
147         * platform/LocalizedStrings.cpp:
148         (WebCore::textTrackCountryAndLanguageMenuItemText): New.
149         (WebCore::textTrackLanguageMenuItemText): Ditto.
150         (WebCore::closedCaptionTrackMenuItemText): Ditto.
151         (WebCore::sdhTrackMenuItemText): Ditto.
152         (WebCore::easyReaderTrackMenuItemText): Ditto.
153         * platform/LocalizedStrings.h:
154
155         * platform/graphics/InbandTextTrackPrivate.h:
156         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
157         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
158         (WebCore::InbandTextTrackPrivateAVFObjC::containsOnlyForcedSubtitles): New, return AVFoundation property.
159         (WebCore::InbandTextTrackPrivateAVFObjC::isMainProgramContent): Ditto.
160         (WebCore::InbandTextTrackPrivateAVFObjC::isEasyToRead): Ditto.
161
162         * testing/InternalSettings.cpp:
163         (WebCore::InternalSettings::setShouldDisplayTrackKind): Set setting via CaptionUserPreferences
164             instead of from Settings.
165         (WebCore::InternalSettings::shouldDisplayTrackKind): Get setting from CaptionUserPreferences
166             instead of from Settings.
167
168 2013-03-20  Zan Dobersek  <zdobersek@igalia.com>
169
170         [GTK] Clean up TemporaryLinkStubs.cpp
171         https://bugs.webkit.org/show_bug.cgi?id=112820
172
173         Reviewed by Philippe Normand.
174
175         Clean up the TemporaryLinkStubs.cpp file, removing unnecessary includes and prettifying the code.
176
177         No new tests - no new functionality.
178
179         * platform/gtk/TemporaryLinkStubs.cpp:
180         (WebCore):
181         (WebCore::getSupportedKeySizes):
182         (WebCore::signedPublicKeyAndChallengeString):
183         (WebCore::userIdleTime):
184
185 2013-03-20  Yufeng Shen  <miletus@chromium.org>
186
187         Remove PlatformEvent::GestureDoubleTap
188         https://bugs.webkit.org/show_bug.cgi?id=93045
189
190         Reviewed by Antonio Gomes.
191
192         PlatformEvent::GestureDoubleTap is not currently
193         used in WebCore and replaced by GestureTap with
194         tap count 2, so remove it.
195
196         Test: We are removing something that is not used, so
197         no new test. All existing tests pass.
198
199         * dom/GestureEvent.cpp:
200         (WebCore::GestureEvent::create):
201         * page/EventHandler.cpp:
202         (WebCore::EventHandler::handleGestureEvent):
203         * platform/PlatformEvent.h:
204         * platform/chromium/PopupContainer.cpp:
205         (WebCore::PopupContainer::handleGestureEvent):
206
207 2013-03-20  Ojan Vafai  <ojan@chromium.org>
208
209         Move repaint methods from RenderObject to RenderBox
210         https://bugs.webkit.org/show_bug.cgi?id=112773
211
212         Reviewed by Julien Chaffraix.
213
214         repaintOverhangingFloats and repaintDuringLayoutIfMoved are only ever called
215         on RenderBoxes, so don't need to be on RenderObject. This also lets us
216         devirtualize repaintDuringLayoutIfMoved.
217
218         * rendering/RenderBox.h:
219         (WebCore::RenderBox::repaintOverhangingFloats):
220         * rendering/RenderObject.cpp:
221         * rendering/RenderObject.h:
222
223 2013-03-20  Christian Biesinger  <cbiesinger@chromium.org>
224
225         Add a feature observer for RenderDeprecatedFlexibleBox
226         https://bugs.webkit.org/show_bug.cgi?id=112740
227
228         Reviewed by Tony Chang.
229
230         No new tests - only adding measurements.
231
232         * page/FeatureObserver.h:
233         Add constants for RenderDeprecatedFlexibleBox, and add separate
234         constants for its use in the UI and in extensions.
235         * rendering/RenderDeprecatedFlexibleBox.cpp:
236         (WebCore::RenderDeprecatedFlexibleBox::RenderDeprecatedFlexibleBox):
237         Call FeatureObserver. Check the document()->url() to see which
238         constant to use.
239
240 2013-03-20  Tim Horton  <timothy_horton@apple.com>
241
242         Autosize should use documentRect height instead of scrollHeight
243         https://bugs.webkit.org/show_bug.cgi?id=112770
244
245         Reviewed by David Levin.
246
247         Autosizing fails to compute the correct height if the root element is very
248         small but the document has significant overflow.
249
250         No new tests; autosizing is not currently exposed in a testable way on Mac.
251
252         * page/FrameView.cpp:
253         (WebCore::FrameView::autoSizeIfEnabled):
254
255 2013-03-20  Julien Chaffraix  <jchaffraix@webkit.org>
256
257         [CSS Grid Layout] Improper repainting when grid item change their position
258         https://bugs.webkit.org/show_bug.cgi?id=112749
259
260         Reviewed by Ojan Vafai.
261
262         Tests: fast/css-grid-layout/grid-element-change-columns-repaint.html
263                fast/css-grid-layout/grid-element-change-rows-repaint.html
264                fast/css-grid-layout/grid-item-change-column-repaint.html
265                fast/css-grid-layout/grid-item-change-row-repaint.html
266
267         * rendering/RenderGrid.cpp:
268         (WebCore::RenderGrid::layoutGridItems):
269         Added a call to repaintDuringLayoutIfMoved to repaint moving grid items.
270
271 2013-03-20  Arvid Nilsson  <anilsson@rim.com>
272
273         [BlackBerry] compositing/iframes/scroll-fixed-transformed-element.html fails in manual testing
274         https://bugs.webkit.org/show_bug.cgi?id=112806
275
276         Reviewed by Antonio Gomes.
277
278         PR 283363
279
280         When scrolling the iframe, the position: fixed element is correctly
281         positioned, that is, as if it was fixed with respect to the iframe's
282         viewport. When scrolling the main frame however, the fixed pos element
283         was positioned as if it was fixed with respect to the main frame's
284         viewport.
285
286         Fixed by falling back to using the WebKit-thread scroll position for
287         fixed positioning in LayerRenderer, if the override doesn't have a
288         position currently set, i.e. if we are not currently scrolling the
289         iframe.
290
291         The effects of the bug are only visual, i.e. not detectable by DRT.
292
293         Manually testable using compositing/iframes/scroll-fixed-transformed-element.html
294
295         * platform/graphics/blackberry/LayerRenderer.cpp:
296         (WebCore::LayerRenderer::updateLayersRecursive):
297
298 2013-03-20  Michael Pruett  <michael@68k.org>
299
300         [V8] Simplify implementation of EnforceRange conversions
301         https://bugs.webkit.org/show_bug.cgi?id=112758
302
303         Reviewed by Kentaro Hara.
304
305         Factor out EnforceRange conversion into a helper function.
306         Simplify calculation for truncation.
307
308         Tests: fast/js/webidl-type-mapping.html
309                storage/indexeddb/cursor-advance.html
310                storage/indexeddb/cursor-advance-workers.html
311                storage/indexeddb/intversion-bad-parameters.html
312
313         * bindings/v8/V8Binding.cpp:
314         (WebCore::enforceRange):
315         (WebCore):
316         (WebCore::toInt32):
317         (WebCore::toUInt32):
318         (WebCore::toInt64):
319         (WebCore::toUInt64):
320
321 2013-03-20  Harald Alvestrand  <hta@google.com>
322
323         Remove Local/Remote and RTCStatsElement from WebRTCStats API
324         https://bugs.webkit.org/show_bug.cgi?id=112678
325
326         Reviewed by Adam Barth.
327
328         Pure removal, remaining functionality covered by existing test.
329
330         * Modules/mediastream/RTCStatsReport.cpp:
331         * Modules/mediastream/RTCStatsReport.h:
332         (RTCStatsReport):
333         * Modules/mediastream/RTCStatsResponse.cpp:
334         * Modules/mediastream/RTCStatsResponse.h:
335         (RTCStatsResponse):
336         * platform/chromium/support/WebRTCStatsResponse.cpp:
337         * platform/mediastream/RTCStatsResponseBase.h:
338         (RTCStatsResponseBase):
339
340 2013-03-20  Xingnan Wang  <xingnan.wang@intel.com>
341
342         ASSERTION FAILED: !m_renderingAutomaticPullNodes.size()
343         https://bugs.webkit.org/show_bug.cgi?id=112777
344
345         Reviewed by Chris Rogers.
346
347         * Modules/webaudio/AudioContext.cpp:
348         (WebCore::AudioContext::~AudioContext):
349
350 2013-03-20  Rouslan Solomakhin  <rouslan@chromium.org>
351
352         Copy-paste should not spellcheck when continuous spellcheck is turned off
353         https://bugs.webkit.org/show_bug.cgi?id=112464
354
355         Reviewed by Ryosuke Niwa.
356
357         Test: editing/spelling/spellcheck-paste-continuous-disabled.html
358
359         * WebCore.exp.in: Export WebCore::Editor::isContinuousSpellCheckingEnabled() and WebCore::Editor::toggleContinuousSpellChecking() for use by internals.
360         * WebCore.order: Export WebCore::Editor::isContinuousSpellCheckingEnabled() and WebCore::Editor::toggleContinuousSpellChecking() for use by internals.
361         * editing/Editor.cpp:
362         (WebCore::Editor::replaceSelectionWithFragment): Do not spellcheck if continuous spellcheck is turned off.
363         * testing/Internals.cpp:
364         (WebCore::Internals::resetToConsistentState): Leave continuous spellcheck turned on after a test.
365         (WebCore::Internals::setContinuousSpellCheckingEnabled): Let tests enable and disable continuous spellcheck.
366         (WebCore):
367         * testing/Internals.h: Let tests enable and disable continuous spellcheck.
368         (Internals):
369         * testing/Internals.idl: Let tests enable and disable continuous spellcheck.
370
371 2013-03-20  Aaron Colwell  <acolwell@chromium.org>
372
373         Add support for MediaSource::isTypeSupported()
374         https://bugs.webkit.org/show_bug.cgi?id=112301
375
376         Reviewed by Darin Fisher.
377
378         Test: http/tests/media/media-source/video-media-source-is-type-supported.html
379
380         * Modules/mediasource/MediaSource.cpp:
381         (WebCore::MediaSource::addSourceBuffer): Added isTypeSupported() call to verify parameters
382                                                  pass into this method.
383         (WebCore::MediaSource::isTypeSupported):
384         (WebCore):
385         * Modules/mediasource/MediaSource.h:
386         (MediaSource):
387         * Modules/mediasource/MediaSource.idl: Added isTypeSupported().
388         * platform/MIMETypeRegistry.h:
389         (MIMETypeRegistry): Added isSupportedMediaSourceMIMEType().
390         * platform/chromium/MIMETypeRegistryChromium.cpp:
391         (WebCore):
392         (WebCore::MIMETypeRegistry::isSupportedMediaSourceMIMEType): Implemented in terms of WebMimeRegistry::isSupportedMediaSourceMIMEType.
393
394 2013-03-20  Brent Fulgham  <bfulgham@webkit.org>
395
396         [WinCairo] Unreviewed VS2010 build correction.
397
398         * WebCore.vcxproj/WebCore.vcxproj: Enable build of NetworkStorageSessionStub.cpp
399         for WinCairo port.
400         * WebCore.vcxproj/WebCore.vcxproj.filters: Correct build type of
401         CookieJarCurl from 'custom' to 'C++ source file'
402
403 2013-03-20  Marja Hölttä  <marja@chromium.org>
404
405         [V8] Rename DOMDataStore::isMainWorldObject
406         https://bugs.webkit.org/show_bug.cgi?id=112817
407
408         Reviewed by Jochen Eisinger.
409
410         No new tests (no changes in functionality).
411
412         * bindings/v8/DOMDataStore.h:
413         (WebCore::DOMDataStore::getWrapperFast):
414         (WebCore::DOMDataStore::getWrapper):
415         (WebCore::DOMDataStore::getWrapperForMainWorld):
416         (WebCore::DOMDataStore::setWrapper):
417         (WebCore::DOMDataStore::canExistInWorker):
418
419 2013-03-20  Ilya Tikhonovsky  <loislo@chromium.org>
420
421         Web Inspector: Flame Chart. Provide Overview pane for better user expirience.
422         https://bugs.webkit.org/show_bug.cgi?id=112496
423
424         Reviewed by Yury Semikhatsky.
425
426         This patch implements basic part of Overview Pane in FlameChart.
427         The idea of the patch is to move everything into chart-container element.
428         And put OverviewGrid into new overview-container element.
429
430         Drive by change: fix the layout of the flame chart elements.
431         Drive by change: fix the drag window & drag resizer mechanics
432         for the case when the parent element has zero offsetLeft.
433
434         * inspector/front-end/FlameChart.js:
435         (WebInspector.FlameChart):
436         (WebInspector.FlameChart.OverviewCalculator):
437         (WebInspector.FlameChart.OverviewCalculator.prototype._updateBoundaries):
438         (WebInspector.FlameChart.OverviewCalculator.prototype.computePosition):
439         (WebInspector.FlameChart.OverviewCalculator.prototype.formatTime):
440         (WebInspector.FlameChart.OverviewCalculator.prototype.maximumBoundary):
441         (WebInspector.FlameChart.OverviewCalculator.prototype.minimumBoundary):
442         (WebInspector.FlameChart.OverviewCalculator.prototype.boundarySpan):
443         (WebInspector.FlameChart.prototype._onWindowChanged):
444         (WebInspector.FlameChart.prototype._adjustXScale):
445         (WebInspector.FlameChart.prototype.update):
446         * inspector/front-end/OverviewGrid.js:
447         (WebInspector.OverviewGrid.Window):
448         (WebInspector.OverviewGrid.Window.prototype._resizerElementStartDragging):
449         (WebInspector.OverviewGrid.Window.prototype._leftResizeElementDragging):
450         (WebInspector.OverviewGrid.Window.prototype._rightResizeElementDragging):
451         (WebInspector.OverviewGrid.Window.prototype._startWindowSelectorDragging):
452         (WebInspector.OverviewGrid.Window.prototype._windowSelectorDragging):
453         (WebInspector.OverviewGrid.Window.prototype._endWindowSelectorDragging):
454         (WebInspector.OverviewGrid.Window.prototype._setWindowPosition):
455         (WebInspector.OverviewGrid.Window.prototype._onMouseWheel):
456         (WebInspector.OverviewGrid.WindowSelector):
457         * inspector/front-end/TimelineOverviewPane.js:
458         * inspector/front-end/flameChart.css:
459         (.chart-container .item-anchor):
460         (.overview-container):
461         (.chart-container):
462         (#flame-chart-overview-grid .resources-dividers-label-bar):
463         * inspector/front-end/inspectorCommon.css:
464         (.resources-divider-label):
465
466 2013-03-20  Sergey Ryazanov  <serya@chromium.org>
467
468         Web Inspector: Plumbing CSS warnings
469         https://bugs.webkit.org/show_bug.cgi?id=111334
470
471         Reviewed by Pavel Feldman.
472
473         Adding a framework for plumbing CSS warnings from CSSParser/grammar to the Inspector console.
474
475         * css/CSSParser.cpp:
476         (WebCore::CSSParser::CSSParser):
477         (WebCore::CSSParser::parseSheet):
478         (WebCore::CSSParser::syntaxError):
479         (WebCore):
480         (WebCore::CSSParser::isLoggingErrors):
481         (WebCore::CSSParser::logError):
482         * css/CSSParser.h:
483         (CSSParser):
484         (CSSParser::Location):
485         (WebCore):
486         * css/StyleSheetContents.cpp:
487         (WebCore::StyleSheetContents::parseAuthorStyleSheet):
488         (WebCore::StyleSheetContents::parseString):
489         (WebCore::StyleSheetContents::parseStringAtLine):
490         * css/StyleSheetContents.h:
491         (StyleSheetContents):
492         * dom/StyleElement.cpp:
493         (WebCore::StyleElement::createSheet):
494         * page/PageConsole.cpp:
495         (WebCore::PageConsole::addMessage):
496
497 2013-03-20  Justin Novosad  <junov@google.com>
498
499         [Chromium] Code cleanup: removing support for non-deferred 2d canvas rendering
500         https://bugs.webkit.org/show_bug.cgi?id=112605
501
502         Reviewed by James Robinson.
503
504         Deleting all the code that was used for propagating and supporting
505         the Chromium setting for disabling deferred 2d canvas rendering.
506
507         No new tests: Affected code paths covered by existing tests.
508
509         * html/HTMLCanvasElement.cpp:
510         (WebCore::HTMLCanvasElement::createImageBuffer):
511         * html/HTMLCanvasElement.h:
512         * page/Settings.in:
513         * platform/graphics/ImageBuffer.h:
514         (WebCore::ImageBuffer::create):
515         (ImageBuffer):
516         * platform/graphics/blackberry/ImageBufferBlackBerry.cpp:
517         (WebCore::ImageBuffer::ImageBuffer):
518         * platform/graphics/cairo/ImageBufferCairo.cpp:
519         (WebCore::ImageBuffer::ImageBuffer):
520         * platform/graphics/cg/ImageBufferCG.cpp:
521         (WebCore::ImageBuffer::ImageBuffer):
522         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
523         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
524         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
525         (WebCore::Canvas2DLayerBridge::prepareForDraw):
526         (WebCore::Canvas2DLayerBridge::storageAllocatedForRecordingChanged):
527         (WebCore::Canvas2DLayerBridge::storageAllocatedForRecording):
528         (WebCore::Canvas2DLayerBridge::freeMemoryIfPossible):
529         (WebCore::Canvas2DLayerBridge::flush):
530         (WebCore::Canvas2DLayerBridge::skCanvas):
531         (WebCore::Canvas2DLayerBridge::prepareTexture):
532         (WebCore::Canvas2DLayerBridge::contextAcquired):
533         * platform/graphics/chromium/Canvas2DLayerBridge.h:
534         (WebCore::Canvas2DLayerBridge::create):
535         (Canvas2DLayerBridge):
536         * platform/graphics/qt/ImageBufferQt.cpp:
537         (WebCore::ImageBuffer::ImageBuffer):
538         * platform/graphics/skia/ImageBufferSkia.cpp:
539         (WebCore::createAcceleratedCanvas):
540         (WebCore::ImageBuffer::ImageBuffer):
541         * platform/graphics/wince/ImageBufferWinCE.cpp:
542         (WebCore::ImageBuffer::ImageBuffer):
543         * platform/graphics/wx/ImageBufferWx.cpp:
544         (WebCore::ImageBuffer::ImageBuffer):
545
546 2013-03-20  Mike West  <mkwst@chromium.org>
547
548         Drop full URLs from cross-domain access errors caused by 'document.domain' mismatches.
549         https://bugs.webkit.org/show_bug.cgi?id=112813
550
551         Reviewed by Timothy Hatcher.
552
553         Following up on http://wkbug.com/112042, this patch brings 'document.domain'
554         mismatch error messages into line with the newly origin-only default
555         message. There will probably be two or three more patches in this series
556         just to keep the rebaselines down to something managably reviewable.
557
558         * page/DOMWindow.cpp:
559         (WebCore::DOMWindow::crossDomainAccessErrorMessage):
560             Move the default message redefinition up out of the final 'return' so
561             that 'document.domain' mismatch errors grab the new text.
562
563 2013-03-20  Ken Kania  <kkania@chromium.org>
564
565         Web Inspector: Add promptText param to Page.handleJavaScriptDialog
566         https://bugs.webkit.org/show_bug.cgi?id=112706
567
568         Reviewed by Pavel Feldman.
569
570         * inspector/Inspector.json:
571         * inspector/InspectorClient.h:
572         (WebCore::InspectorClient::handleJavaScriptDialog):
573         * inspector/InspectorPageAgent.cpp:
574         (WebCore::InspectorPageAgent::handleJavaScriptDialog):
575         * inspector/InspectorPageAgent.h:
576
577 2013-03-20  Andrey Lushnikov  <lushnikov@chromium.org>
578
579         Web Inspector: fix SourceFrame.js compilation warning
580         https://bugs.webkit.org/show_bug.cgi?id=112804
581
582         Reviewed by Yury Semikhatsky.
583
584         No new tests: no change in behavior.
585
586         - Explicitly parse lineNumber from object property name.
587         - Add type annotations to ensure addMessageToSource is monomorphic.
588
589         * inspector/front-end/SourceFrame.js:
590         (WebInspector.SourceFrame.prototype.clearMessages):
591
592 2013-03-20  Dan Carney  <dcarney@google.com>
593
594         [v8] unsafe persistent access in V8LazyEventListener
595         https://bugs.webkit.org/show_bug.cgi?id=112807
596
597         Reviewed by Kentaro Hara.
598
599         No new tests.
600
601         * bindings/v8/V8LazyEventListener.cpp:
602         (WebCore::toObjectWrapper):
603
604 2013-03-20  Arvid Nilsson  <anilsson@rim.com>
605
606         [BlackBerry] Enable appropriate vertex attribute arrays in LayerRenderer::useProgram()
607         https://bugs.webkit.org/show_bug.cgi?id=112757
608
609         Reviewed by Rob Buis.
610
611         PR 306465
612
613         Make the LayerRenderer and associated code more bullet-proof when it
614         comes to enabling vertex attribute arrays, by enabling them already
615         when LayerRenderer::useProgram() is called. This fixes a bug where the
616         video hole punch rectangle wasn't punched when preceding rendering
617         caused the vertex attribute array at index 0 to be disabled, such as
618         when rendering the text selection overlay immediately before video.
619
620         A number of places where the position attribute index was hard-coded
621         to 0 were also fixed. This causes no change in behavior, the position
622         attribute was really at 0, but nonetheless that shouldn't be hardcoded.
623
624         The effects of this patch are only manually testable.
625
626         * platform/graphics/blackberry/LayerCompositingThread.cpp:
627         (WebCore::LayerCompositingThread::drawTextures):
628         (WebCore::LayerCompositingThread::drawSurface):
629         * platform/graphics/blackberry/LayerRenderer.cpp:
630         (WebCore::LayerRenderer::compositeBuffer):
631         (WebCore::LayerRenderer::drawColor):
632         (WebCore::LayerRenderer::drawDebugBorder):
633         (WebCore::LayerRenderer::drawHolePunchRect):
634         (WebCore::LayerRenderer::compositeLayersRecursive):
635         (WebCore::LayerRenderer::useProgram):
636
637 2013-03-20  Andrey Lushnikov  <lushnikov@chromium.org>
638
639         Web Inspector: [CodeMirror] implement highlightRange method
640         https://bugs.webkit.org/show_bug.cgi?id=112802
641
642         Reviewed by Vsevolod Vlasov.
643
644         - Implement highlightRange/removeHighlight methods in
645         CodeMirrorTextEditor.
646         - Update TextEditor interface closure annotations.
647
648         No new tests.
649
650         * inspector/front-end/CodeMirrorTextEditor.js:
651         (WebInspector.CodeMirrorTextEditor.prototype.removeHighlight):
652         (WebInspector.CodeMirrorTextEditor.prototype.highlightRange):
653         * inspector/front-end/DefaultTextEditor.js:
654         * inspector/front-end/TextEditor.js:
655
656 2013-03-20  Andrey Lushnikov  <lushnikov@chromium.org>
657
658         Web Inspector: [CodeMirror] show source location for codemirror text editor
659         https://bugs.webkit.org/show_bug.cgi?id=112798
660
661         Reviewed by Vsevolod Vlasov.
662
663         No new tests.
664
665         - Implement CodeMirrorTextEditor.copyRange method
666         - Fire "selectionChange" event for text editor delegate from
667         CodeMirrorTextEditor.
668
669         * inspector/front-end/CodeMirrorTextEditor.js:
670         (WebInspector.CodeMirrorTextEditor):
671         (WebInspector.CodeMirrorTextEditor.prototype.copyRange):
672         (WebInspector.CodeMirrorTextEditor.prototype._cursorActivity):
673
674 2013-03-20  Sheriff Bot  <webkit.review.bot@gmail.com>
675
676         Unreviewed, rolling out r146331.
677         http://trac.webkit.org/changeset/146331
678         https://bugs.webkit.org/show_bug.cgi?id=112795
679
680         Does not work as expected (Requested by carewolf on #webkit).
681
682         * platform/graphics/qt/FontQt.cpp:
683         (WebCore::Font::initFormatForTextLayout):
684
685 2013-03-20  Eugene Klyuchnikov  <eustas@chromium.org>
686
687         Web Inspector: [Resources] Local Storage: "Add item" row height doesn't match underlying grid.
688         https://bugs.webkit.org/show_bug.cgi?id=112433
689
690         Reviewed by Pavel Feldman.
691
692         Fixed cell height to correspond grid step.
693
694         * inspector/front-end/dataGrid.css:
695         (.data-grid td): Fixed cell height to correspond grid step.
696
697 2013-03-20  Allan Sandfeld Jensen  <allan.jensen@digia.com>
698
699         [Qt] New fast/text/word-space-with-kerning-3.html fails on Qt
700         https://bugs.webkit.org/show_bug.cgi?id=112668
701
702         Reviewed by Jocelyn Turcotte.
703
704         Kerning is on by default in Qt. This means we need to disable it
705         when WebCore does not request it.
706
707         * platform/graphics/qt/FontQt.cpp:
708         (WebCore::Font::initFormatForTextLayout):
709
710 2013-03-20  Ilya Tikhonovsky  <loislo@chromium.org>
711
712         Web Inspector: OverviewGrid rename classes according to names of js classes.
713         https://bugs.webkit.org/show_bug.cgi?id=112786
714
715         Reviewed by Yury Semikhatsky.
716
717         It is a part of meta bug 'extract OverviewGrid from TimelineOverviewPane'.
718         As the last step it renames timeline-...... classes to overview-grid-...... classes
719         and moves them to inspectorCommon.css
720
721         * inspector/front-end/OverviewGrid.js:
722         (WebInspector.OverviewGrid):
723         (WebInspector.OverviewGrid.Window):
724         (WebInspector.OverviewGrid.Window.prototype._startWindowSelectorDragging):
725         (WebInspector.OverviewGrid.WindowSelector):
726         (WebInspector.OverviewGrid.WindowSelector.prototype._createSelectorElement):
727         * inspector/front-end/inspectorCommon.css:
728         (.overview-grid-window-selector):
729         (.overview-grid-window):
730         (.overview-grid-dividers-background):
731         (.overview-grid-window-rulers):
732         (.overview-grid-window-resizer):
733         * inspector/front-end/timelinePanel.css:
734         (.timeline-frame-overview .overview-grid-window):
735         (.timeline-frame-overview .overview-grid-dividers-background):
736
737 2013-03-20  Dmitry Zvorygin  <zvorygin@chromium.org>
738
739         Web Inspector: Switch Drawer animation from JavaScript to CSS transitions.
740         https://bugs.webkit.org/show_bug.cgi?id=112586
741
742         This is prerequisite to make Drawer work in overlay mode.
743
744         Reviewed by Vsevolod Vlasov.
745
746         * inspector/front-end/Drawer.js:
747         (WebInspector.Drawer):
748         (WebInspector.Drawer.prototype.show):
749         (WebInspector.Drawer.prototype.hide.this.animationFinished):
750         (WebInspector.Drawer.prototype.hide):
751         (WebInspector.Drawer.prototype.immediatelyFinishAnimation):
752         (WebInspector.Drawer.prototype._getAnimationStyles):
753         * inspector/front-end/UIUtils.js:
754         * inspector/front-end/inspector.css:
755         (.animate-slow *):
756         (.animate #main):
757         (.animate #floating-status-bar-container):
758         (.animate #drawer):
759         (.animate #bottom-status-bar-container > *):
760
761 2013-03-19  Eugene Klyuchnikov  <eustas@chromium.org>
762
763         Web Inspector: [DataGrid] Refactorings.
764         https://bugs.webkit.org/show_bug.cgi?id=112690
765
766         Reviewed by Pavel Feldman.
767
768         1. Avoid using string literals;
769         2. Remove unused notifications; turn "populate" to method invocation;
770         3. Replace some getters with regular functions.
771
772         * inspector/front-end/DataGrid.js: Applied refactorings.
773         * inspector/front-end/ApplicationCacheItemsView.js: Adopted changes.
774         * inspector/front-end/BottomUpProfileDataGridTree.js: Ditto.
775         * inspector/front-end/CPUProfileView.js: Ditto.
776         * inspector/front-end/CSSSelectorProfileView.js: Ditto.
777         * inspector/front-end/CookiesTable.js: Ditto.
778         * inspector/front-end/DirectoryContentView.js: Ditto.
779         * inspector/front-end/HeapSnapshotDataGrids.js: Ditto.
780         * inspector/front-end/HeapSnapshotGridNodes.js: Ditto.
781         * inspector/front-end/NativeMemorySnapshotView.js: Ditto.
782         * inspector/front-end/NetworkPanel.js: Ditto.
783         * inspector/front-end/ProfileDataGridTree.js: Ditto.
784         * inspector/front-end/ResourceWebSocketFrameView.js: Ditto.
785         * inspector/front-end/TopDownProfileDataGridTree.js: Ditto.
786         * inspector/front-end/dataGrid.css: Ditto.
787
788 2013-03-19  Allan Sandfeld Jensen  <allan.jensen@digia.com>
789
790         [Qt] Support -webkit-font-smoothing
791         https://bugs.webkit.org/show_bug.cgi?id=106009
792
793         Reviewed by Jocelyn Turcotte.
794
795         Set QFont antialiasing settings based on the font smoothing settings in FontDescription.
796
797         * platform/graphics/qt/FontPlatformDataQt.cpp:
798         (WebCore::FontPlatformData::FontPlatformData):
799
800 2013-03-20  Alexei Filippov  <alph@chromium.org>
801
802         Web Inspector: Allow toolbar customization
803         https://bugs.webkit.org/show_bug.cgi?id=112440
804
805         Adds a tools menu item that allows the user to show/hide
806         inspector panels on the toolbar.
807
808         Reviewed by Yury Semikhatsky.
809
810         * inspector/front-end/InspectorView.js:
811         * inspector/front-end/Settings.js:
812         (WebInspector.Settings):
813         (WebInspector.ExperimentsSettings):
814         * inspector/front-end/Toolbar.js:
815         (WebInspector.Toolbar):
816         (WebInspector.Toolbar.prototype.addPanel):
817         (WebInspector.Toolbar.prototype._isPanelVisibleByDefault):
818         (WebInspector.Toolbar.prototype.set _hidePanel):
819         (WebInspector.Toolbar.prototype._showPanel):
820         (WebInspector.Toolbar.prototype._togglePanelsMenu):
821         * inspector/front-end/inspector.css:
822         (#toolbar-panels-menu):
823         (#toolbar-panels-menu:hover):
824         (#toolbar-panels-menu:active):
825         * inspector/front-end/inspector.html:
826
827 2013-03-20  Eugene Klyuchnikov  <eustas@chromium.org>
828
829         Web Inspector: [Settings] Add "storage" parameter to WebInspector.Setting
830         https://bugs.webkit.org/show_bug.cgi?id=112667
831
832         Reviewed by Pavel Feldman.
833
834         New parameter will allow more options on how long setting will persist.
835         Possible options are: localStorage, sessionStorage and no-storage.
836
837         Additional change: use delete instead of .removeItem to make it possible
838         use any object as storage.
839
840         * inspector/front-end/Settings.js:
841         Added "storage" parameter and used is instead of "window.localStorage".
842
843 2013-03-20  Pan Deng  <pan.deng@intel.com>
844
845         Web Inspector: [Network] Fix the bug of WebSocketFrameView crash.
846         https://bugs.webkit.org/show_bug.cgi?id=112771.
847
848         Reviewed by Pavel Feldman.
849
850         WebSocketFrameView crashes when websocket receives an error message, this
851         patch fixes this problem, and error message will be shown in dataGrid as expected.
852
853         No new tests.
854
855         * inspector/front-end/ResourceWebSocketFrameView.js:
856         (WebInspector.ResourceWebSocketFrameView): Handle the errorMessage case.
857
858 2013-03-20  Dmitry Zvorygin  <zvorygin@chromium.org>
859
860         Remove remainings of obsolete LogLevels and MessageSources from inspector JS part.
861         https://bugs.webkit.org/show_bug.cgi?id=112709
862
863         By the way tuned messagesources in ApplicationCacheGroup.
864
865         Reviewed by Pavel Feldman.
866
867         * inspector/front-end/ConsoleMessage.js:
868         (WebInspector.ConsoleMessageImpl.prototype.toMessageElement):
869         (WebInspector.ConsoleMessageImpl.prototype.toString):
870         * inspector/front-end/ConsoleModel.js:
871         * inspector/front-end/ExtensionAPI.js:
872         (defineCommonExtensionSymbols):
873         * inspector/front-end/ExtensionServer.js:
874         (WebInspector.ExtensionServer.prototype._onAddConsoleMessage):
875         (WebInspector.ExtensionServer.prototype._makeConsoleMessage):
876         * loader/appcache/ApplicationCacheGroup.cpp:
877         (WebCore::ApplicationCacheGroup::didReceiveResponse):
878         (WebCore::ApplicationCacheGroup::didFinishLoading):
879         (WebCore::ApplicationCacheGroup::didFail):
880
881 2013-03-20  Krzysztof Czech  <k.czech@samsung.com>
882
883         [GTK] accessibility/aria-scrollbar-role.html is failing
884         https://bugs.webkit.org/show_bug.cgi?id=98358
885
886         Reviewed by Martin Robinson.
887
888         Adds support for checking an orientation attribute of accessibility object.
889         AccessibilityObject that represents ScrollBar element should be ATK_VALUE type.
890         ScrollBar element can be considered as a Range Widget that is able to expose some
891         range values.
892
893         Test: accessibility/aria-scrollbar-role.html
894
895         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
896         (setAtkStateSetFromCoreObject):
897         (getInterfaceMaskFromObject):
898
899 2013-03-20  Zan Dobersek  <zdobersek@igalia.com>
900
901         Unreviewed. Fixing a typo in libLevelDB_la_CFLAGS assignment - cxflags -> cflags.
902
903         * GNUmakefile.am:
904
905 2013-03-20  Robert Hogan  <robert@webkit.org>
906
907         Absolute position div without width specified does not reflow its text when it is moved (and computed width changes)
908         https://bugs.webkit.org/show_bug.cgi?id=112052
909
910         Reviewed by Emil A Eklund.
911         
912         If a positioned block has auto width then any movement means the block needs to be resized.
913
914         Test: fast/block/positioned-block-auto-width-movement.html
915
916         * rendering/style/RenderStyle.cpp:
917         (WebCore::positionedObjectMoved):
918         (WebCore::RenderStyle::diff):
919
920 2013-03-19  Sheriff Bot  <webkit.review.bot@gmail.com>
921
922         Unreviewed, rolling out r146301.
923         http://trac.webkit.org/changeset/146301
924         https://bugs.webkit.org/show_bug.cgi?id=112776
925
926         Caused hundreds of tests to hit assertions on Windows debug
927         bots (Requested by rniwa on #webkit).
928
929         * CMakeLists.txt:
930         * GNUmakefile.list.am:
931         * Target.pri:
932         * WebCore.exp.in:
933         * WebCore.gypi:
934         * WebCore.vcproj/WebCore.vcproj:
935         * WebCore.vcxproj/WebCore.vcxproj:
936         * WebCore.vcxproj/WebCore.vcxproj.filters:
937         * WebCore.xcodeproj/project.pbxproj:
938         * loader/DocumentLoader.cpp:
939         (WebCore::DocumentLoader::DocumentLoader):
940         (WebCore::DocumentLoader::mainResourceLoader):
941         (WebCore::DocumentLoader::~DocumentLoader):
942         (WebCore::DocumentLoader::mainResourceData):
943         (WebCore::DocumentLoader::stopLoading):
944         (WebCore::DocumentLoader::finishedLoading):
945         (WebCore::DocumentLoader::handleSubstituteDataLoadNow):
946         (WebCore::DocumentLoader::continueAfterNavigationPolicy):
947         (WebCore::DocumentLoader::responseReceived):
948         (WebCore::DocumentLoader::continueAfterContentPolicy):
949         (WebCore::DocumentLoader::reportMemoryUsage):
950         (WebCore::DocumentLoader::receivedData):
951         (WebCore::DocumentLoader::clearMainResourceLoader):
952         (WebCore::DocumentLoader::setDefersLoading):
953         (WebCore::DocumentLoader::setMainResourceDataBufferingPolicy):
954         (WebCore::DocumentLoader::addSubresourceLoader):
955         (WebCore::DocumentLoader::isLoadingMainResource):
956         (WebCore):
957         (WebCore::DocumentLoader::maybeLoadEmpty):
958         (WebCore::DocumentLoader::startLoadingMainResource):
959         * loader/DocumentLoader.h:
960         (WebCore):
961         (DocumentLoader):
962         * loader/MainResourceLoader.cpp: Added.
963         (WebCore):
964         (WebCore::MainResourceLoader::MainResourceLoader):
965         (WebCore::MainResourceLoader::~MainResourceLoader):
966         (WebCore::MainResourceLoader::create):
967         (WebCore::MainResourceLoader::clearResource):
968         (WebCore::MainResourceLoader::frameLoader):
969         (WebCore::MainResourceLoader::request):
970         (WebCore::MainResourceLoader::resourceData):
971         (WebCore::MainResourceLoader::redirectReceived):
972         (WebCore::MainResourceLoader::responseReceived):
973         (WebCore::MainResourceLoader::dataReceived):
974         (WebCore::MainResourceLoader::notifyFinished):
975         (WebCore::MainResourceLoader::reportMemoryUsage):
976         (WebCore::MainResourceLoader::load):
977         (WebCore::MainResourceLoader::setDefersLoading):
978         (WebCore::MainResourceLoader::defersLoading):
979         (WebCore::MainResourceLoader::setDataBufferingPolicy):
980         (WebCore::MainResourceLoader::loader):
981         (WebCore::MainResourceLoader::identifier):
982         * loader/MainResourceLoader.h: Added.
983         (WebCore):
984         (MainResourceLoader):
985         (WebCore::MainResourceLoader::cachedMainResource):
986         (WebCore::MainResourceLoader::documentLoader):
987         * loader/mac/DocumentLoaderMac.cpp:
988         (WebCore::DocumentLoader::schedule):
989         (WebCore::DocumentLoader::unschedule):
990
991 2013-03-19  Mike West  <mkwst@chromium.org>
992
993         CSP 1.1: Stub out SecurityPolicyViolationEvent interface.
994         https://bugs.webkit.org/show_bug.cgi?id=112681
995
996         Reviewed by Adam Barth.
997
998         A first pass at a SecurityPolicyViolationEvent interface is defined in
999         CSP 1.1's editor's draft[1]. This patch puts the big components into
1000         place so that we can start getting some implementation experience with
1001         the new event interface as it's defined, and feed that back into the
1002         working group.
1003
1004         Here, we're only defining the interface, and creating a listener on the
1005         Document. Events aren't yet being fired when Content Security Policy
1006         violations occur. I'll tackle that in a future patch; adding files is
1007         a big enough annoyance to do it separately.
1008
1009         This patch has only two web-visible impacts:
1010
1011         - Document objects now have an 'onsecuritypolicyviolation' attribute.
1012         - A SecurityPolicyViolationEvent constructor is accessible on the Window object.
1013
1014         Ports that have not enabled the CSP_NEXT flag should experience no change.
1015
1016         [1]: https://dvcs.w3.org/hg/content-security-policy/raw-file/tip/csp-specification.dev.html#securitypolicyviolationevent-events
1017
1018         Test: http/tests/security/contentSecurityPolicy/1.1/securitypolicyviolation-basics.html
1019
1020         * CMakeLists.txt:
1021         * GNUmakefile.list.am:
1022         * WebCore.gypi:
1023         * WebCore.vcproj/WebCore.vcproj:
1024         * WebCore.xcodeproj/project.pbxproj:
1025             Wow! A new file! This is so exciting! I'm going to tell ALL my build
1026             systems about this!
1027         * dom/Document.h:
1028         * dom/Document.idl:
1029             Define an 'onsecuritypolicyviolation' event handler on Document objects.
1030         * dom/EventNames.h:
1031         * dom/EventNames.in:
1032             Define a 'securitypolicyviolation' event type.
1033         * dom/SecurityPolicyViolationEvent.h: Added.
1034         (WebCore::SecurityPolicyViolationEventInit::SecurityPolicyViolationEventInit):
1035         (SecurityPolicyViolationEventInit):
1036         (SecurityPolicyViolationEvent):
1037         (WebCore::SecurityPolicyViolationEvent::create):
1038         (WebCore::SecurityPolicyViolationEvent::documentURI):
1039         (WebCore::SecurityPolicyViolationEvent::referrer):
1040         (WebCore::SecurityPolicyViolationEvent::blockedURI):
1041         (WebCore::SecurityPolicyViolationEvent::violatedDirective):
1042         (WebCore::SecurityPolicyViolationEvent::effectiveDirective):
1043         (WebCore::SecurityPolicyViolationEvent::originalPolicy):
1044         (WebCore::SecurityPolicyViolationEvent::sourceURL):
1045         (WebCore::SecurityPolicyViolationEvent::lineNumber):
1046         (WebCore::SecurityPolicyViolationEvent::interfaceName):
1047         (WebCore::SecurityPolicyViolationEvent::SecurityPolicyViolationEvent):
1048         * dom/SecurityPolicyViolationEvent.idl: Added.
1049             Define the SecurityPolicyViolationEvent's IDL, and then create all the
1050             boilerplate necessary to properly initialize a SecurityPolicyViolationEvent
1051             object with the relevant properties.
1052         * page/DOMWindow.idl:
1053             Add the new SecurityPolicyViolationEvent constructor to the Window object
1054             so it's available on a page.
1055
1056 2013-03-19  Eugene Klyuchnikov  <eustas@chromium.org>
1057
1058         Web Inspector: [Timeline] Tune status bar UI for limited-width window.
1059         https://bugs.webkit.org/show_bug.cgi?id=112702
1060
1061         Reviewed by Pavel Feldman.
1062
1063         Reduce filter titles when there is not enough space.
1064
1065         * inspector/front-end/TimelinePanel.js: Add classnames to elements.
1066         * inspector/front-end/timelinePanel.css: Specify "flex" behaviour.
1067
1068 2013-03-19  Nate Chapin  <japhet@chromium.org>
1069
1070         Merge MainResourceLoader into DocumentLoader
1071         https://bugs.webkit.org/show_bug.cgi?id=104969
1072
1073         Reviewed by Adam Barth.
1074
1075         No new tests, refactor only.
1076
1077         * CMakeLists.txt:
1078         * GNUmakefile.list.am:
1079         * Target.pri:
1080         * WebCore.exp.in:
1081         * WebCore.gypi:
1082         * WebCore.vcproj/WebCore.vcproj:
1083         * WebCore.vcxproj/WebCore.vcxproj:
1084         * WebCore.vcxproj/WebCore.vcxproj.filters:
1085         * WebCore.xcodeproj/project.pbxproj:
1086         * loader/DocumentLoader.cpp:
1087         (WebCore::DocumentLoader::DocumentLoader):
1088         (WebCore::DocumentLoader::mainResourceLoader):
1089         (WebCore::DocumentLoader::~DocumentLoader): Move main resource clearing from
1090             ~MainResourceLoader.
1091         (WebCore::DocumentLoader::mainResourceData):
1092         (WebCore::DocumentLoader::stopLoading):
1093         (WebCore::DocumentLoader::notifyFinished): Moved from MainResourceLoader::notifyFinished.
1094         (WebCore):
1095         (WebCore::DocumentLoader::finishedLoading):
1096         (WebCore::DocumentLoader::handleSubstituteDataLoadNow):
1097         (WebCore::DocumentLoader::redirectReceived):
1098         (WebCore::DocumentLoader::continueAfterNavigationPolicy):
1099         (WebCore::DocumentLoader::responseReceived):
1100         (WebCore::DocumentLoader::continueAfterContentPolicy):
1101         (WebCore::DocumentLoader::reportMemoryUsage):
1102         (WebCore::DocumentLoader::dataReceived):
1103         (WebCore::DocumentLoader::clearMainResourceLoader):
1104         (WebCore::DocumentLoader::setDefersLoading):
1105         (WebCore::DocumentLoader::setMainResourceDataBufferingPolicy):
1106         (WebCore::DocumentLoader::addSubresourceLoader):
1107         (WebCore::DocumentLoader::maybeLoadEmpty):
1108         (WebCore::DocumentLoader::startLoadingMainResource): Don't keep separate checks
1109              for normal and empty loads, just use a single boolean.
1110         * loader/DocumentLoader.h:
1111         (WebCore::DocumentLoader::isLoadingMainResource):
1112         * loader/MainResourceLoader.cpp: Removed.
1113         * loader/MainResourceLoader.h: Removed.
1114         * loader/mac/DocumentLoaderMac.cpp:
1115         (WebCore::DocumentLoader::schedule):
1116         (WebCore::DocumentLoader::unschedule):
1117
1118 2013-03-19  Ankur Taly  <ataly@google.com>
1119
1120         Cache a pointer to V8DOMActivityLogger in PerContextData.
1121         https://bugs.webkit.org/show_bug.cgi?id=112719
1122
1123         Reviewed by Kentaro Hara.
1124
1125         Adds a data member (and getter, setter methods) to V8PerContextData
1126         that holds a pointer to a V8DOMActivityLogger. This member is set while
1127         initializing the context for a V8DOMWindowShell. Ownership of the pointer
1128         is still retained by the HashMap in DOMWrapperWorld.
1129         As a result of this patch, subsequent patches that will implement logging
1130         for DOM API access (See bug 107207) will be able to obtain a reference to
1131         the logger directly from PerContextData. This will benefit performance as it
1132         will be faster than looking up the logger in the DOMActivityLoggerMap in
1133         DOMWrapperWorld.
1134
1135         There are no new tests as there is no change in behavior.
1136
1137         * bindings/v8/V8DOMWindowShell.cpp:
1138         (WebCore::V8DOMWindowShell::initializeIfNeeded):
1139         * bindings/v8/V8PerContextData.h:
1140         (WebCore::V8PerContextData::activityLogger):
1141         (V8PerContextData):
1142         (WebCore::V8PerContextData::setActivityLogger):
1143
1144 2013-03-19  Arnaud Renevier  <a.renevier@sisa.samsung.com>
1145
1146         do not use string reference for enum support in CodeGeneratorJS.pm
1147         https://bugs.webkit.org/show_bug.cgi?id=112760
1148
1149         Reviewed by Kentaro Hara.
1150
1151         Do use string references in generated JS bindings for enum values.
1152
1153         Test: bindings/scripts/test/TestObj.idl
1154
1155         * bindings/scripts/CodeGeneratorJS.pm:
1156         (GenerateImplementation):
1157         (GenerateParametersCheck):
1158         * bindings/scripts/test/JS/JSTestObj.cpp:
1159         (WebCore::setJSTestObjEnumAttr):
1160         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
1161
1162 2013-03-19  Simon Fraser  <simon.fraser@apple.com>
1163
1164         Make RLC::haveNonMainLayersWithTiledBacking() public and fix the name
1165         https://bugs.webkit.org/show_bug.cgi?id=112763
1166
1167         Reviewed by Tim Horton.
1168
1169         Downstream code needs to call hasNonMainLayersWithTiledBacking().
1170
1171         * rendering/RenderLayerCompositor.h:
1172         (WebCore::RenderLayerCompositor::hasNonMainLayersWithTiledBacking):
1173         (RenderLayerCompositor):
1174
1175 2013-03-19  David Levin  <levin@chromium.org>
1176
1177         FrameLoader::didChangeIcons isn't called when the favicon is changed.
1178         https://bugs.webkit.org/show_bug.cgi?id=112080
1179
1180         Reviewed by Dmitry Titov.
1181
1182         Test: fast/dom/icon-url-property.html
1183
1184         * dom/Document.cpp:
1185         (WebCore::Document::addIconURL): Made the callback for didChangeIcons
1186         happen whenever there are favicon changes instead of filtering it
1187         and have to be in sync about what hosts care about. As far as I could
1188         tell no hosts rely on this callback except for Chromium, so in general
1189         doing less work here may potentially help a small amount for other
1190         ports.
1191
1192 2013-03-19  Michael Pruett  <michael@68k.org>
1193
1194         Don't throw on infinity or NaN index in HTMLOptionsCollection.add()
1195         https://bugs.webkit.org/show_bug.cgi?id=112612
1196
1197         Reviewed by Kentaro Hara.
1198
1199         HTMLOptionsCollection.add() should not throw a type error when
1200         its optional index argument is infinity or NaN. Such values
1201         should instead be converted to 0 with no error.
1202
1203         Tests: fast/dom/non-numeric-values-numeric-parameters.html
1204                fast/js/select-options-add.html
1205
1206         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
1207         (WebCore::JSHTMLOptionsCollection::add):
1208
1209 2013-03-19  Dominic Mazzoni  <dmazzoni@google.com>
1210
1211         Security: Heap-use-after-free in WebCore::AXObjectCache::getOrCreate
1212         https://bugs.webkit.org/show_bug.cgi?id=112044
1213
1214         Reviewed by Chris Fleizach.
1215
1216         Always call recalcSectionsIfNeeded before accessing
1217         table sections.
1218
1219         Test: accessibility/table-remove-cell-crash.html
1220
1221         * accessibility/AccessibilityTable.cpp:
1222         (WebCore::AccessibilityTable::addChildren):
1223
1224 2013-03-19  Arnaud Renevier  <a.renevier@sisa.samsung.com>
1225
1226         [v8] add IDL 'enum' in DOM methods
1227         https://bugs.webkit.org/show_bug.cgi?id=112644
1228
1229         Reviewed by Kentaro Hara.
1230
1231         This adds V8 support for enumerations in method parameters.
1232
1233         Test: bindings/scripts/test/TestObj.idl
1234
1235         * bindings/scripts/CodeGeneratorV8.pm:
1236         (GenerateParametersCheck):
1237         * bindings/scripts/test/V8/V8TestObj.cpp:
1238         (WebCore::TestObjV8Internal::methodWithEnumArgMethod):
1239
1240 2013-03-19  Kenneth Russell  <kbr@google.com>
1241
1242         Unreviewed, rolling out r146277.
1243         http://trac.webkit.org/changeset/146277
1244         https://bugs.webkit.org/show_bug.cgi?id=111695
1245
1246         Broke Chromium Android build
1247
1248         * Modules/speech/SpeechSynthesis.cpp:
1249         (WebCore::SpeechSynthesis::boundaryEventOccurred):
1250         (WebCore::SpeechSynthesis::didStartSpeaking):
1251         (WebCore::SpeechSynthesis::didPauseSpeaking):
1252         (WebCore::SpeechSynthesis::didResumeSpeaking):
1253         (WebCore::SpeechSynthesis::didFinishSpeaking):
1254         (WebCore::SpeechSynthesis::speakingErrorOccurred):
1255         (WebCore):
1256         * Modules/speech/SpeechSynthesis.h:
1257         (SpeechSynthesis):
1258         * Modules/speech/SpeechSynthesisUtterance.cpp:
1259         (WebCore::SpeechSynthesisUtterance::SpeechSynthesisUtterance):
1260         (WebCore::SpeechSynthesisUtterance::setVoice):
1261         * Modules/speech/SpeechSynthesisUtterance.h:
1262         (WebCore::SpeechSynthesisUtterance::text):
1263         (WebCore::SpeechSynthesisUtterance::setText):
1264         (WebCore::SpeechSynthesisUtterance::lang):
1265         (WebCore::SpeechSynthesisUtterance::setLang):
1266         (WebCore::SpeechSynthesisUtterance::volume):
1267         (WebCore::SpeechSynthesisUtterance::setVolume):
1268         (WebCore::SpeechSynthesisUtterance::rate):
1269         (WebCore::SpeechSynthesisUtterance::setRate):
1270         (WebCore::SpeechSynthesisUtterance::pitch):
1271         (WebCore::SpeechSynthesisUtterance::setPitch):
1272         (WebCore::SpeechSynthesisUtterance::startTime):
1273         (WebCore::SpeechSynthesisUtterance::setStartTime):
1274         (WebCore::SpeechSynthesisUtterance::platformUtterance):
1275         (SpeechSynthesisUtterance):
1276         * Modules/speech/SpeechSynthesisVoice.h:
1277         * WebCore.exp.in:
1278         * WebCore.gypi:
1279         * platform/PlatformSpeechSynthesis.h:
1280         (PlatformSpeechSynthesis):
1281         * platform/PlatformSpeechSynthesisUtterance.cpp:
1282         * platform/PlatformSpeechSynthesisUtterance.h:
1283         (PlatformSpeechSynthesisUtterance):
1284         * platform/PlatformSpeechSynthesisVoice.cpp:
1285         (WebCore::PlatformSpeechSynthesisVoice::create):
1286         * platform/PlatformSpeechSynthesisVoice.h:
1287         (PlatformSpeechSynthesisVoice):
1288         * platform/PlatformSpeechSynthesizer.cpp:
1289         (WebCore::PlatformSpeechSynthesizer::create):
1290         (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
1291         (WebCore):
1292         * platform/PlatformSpeechSynthesizer.h:
1293         (PlatformSpeechSynthesizerClient):
1294         (WebCore::PlatformSpeechSynthesizer::~PlatformSpeechSynthesizer):
1295         (PlatformSpeechSynthesizer):
1296         * platform/chromium/PlatformSpeechSynthesizerChromium.cpp: Removed.
1297         * platform/chromium/support/WebSpeechSynthesisUtterance.cpp: Removed.
1298         * platform/chromium/support/WebSpeechSynthesisVoice.cpp: Removed.
1299         * platform/chromium/support/WebSpeechSynthesizerClientImpl.cpp: Removed.
1300         * platform/chromium/support/WebSpeechSynthesizerClientImpl.h: Removed.
1301         * platform/mac/PlatformSpeechSynthesizerMac.mm:
1302         (-[WebSpeechSynthesisWrapper speakUtterance:WebCore::]):
1303         (-[WebSpeechSynthesisWrapper speechSynthesizer:didFinishSpeaking:]):
1304         (WebCore::PlatformSpeechSynthesizer::speak):
1305         * platform/mock/PlatformSpeechSynthesizerMock.cpp:
1306         (WebCore::PlatformSpeechSynthesizerMock::create):
1307         (WebCore::PlatformSpeechSynthesizerMock::PlatformSpeechSynthesizerMock):
1308         (WebCore::PlatformSpeechSynthesizerMock::speakingFinished):
1309         (WebCore::PlatformSpeechSynthesizerMock::speak):
1310         * platform/mock/PlatformSpeechSynthesizerMock.h:
1311         (PlatformSpeechSynthesizerMock):
1312
1313 2013-03-19  Antti Koivisto  <antti@apple.com>
1314
1315         Don't compute background obscuration on every repaint
1316         https://bugs.webkit.org/show_bug.cgi?id=112457
1317
1318         Reviewed by Simon Fraser.
1319
1320         Test: fast/backgrounds/obscured-background-child-style-change.html
1321         
1322         It is generally enough to compute background obscuration status once per layout rather than doing it on every repaint.
1323         Since there are fewer layouts than repaints this will allow more expensive checks in the future.
1324         
1325         With this patch adds caching and invalidation of the obscuration status.
1326
1327         * rendering/RenderBlock.cpp:
1328         (WebCore::RenderBlock::layout):
1329         
1330             Invalidate the obscuration status on layout.
1331
1332         * rendering/RenderBox.cpp:
1333         (WebCore::RenderBox::styleDidChange):
1334         
1335             Invalidate the parent obscuration status if there is repaint-only style change (often background related). 
1336             Tested by the new fast/css/obscured-background-child-style-change.html.
1337
1338         (WebCore::RenderBox::layout):
1339         (WebCore::RenderBox::computeBackgroundIsKnownToBeObscured):
1340         * rendering/RenderBox.h:
1341         * rendering/RenderImage.cpp:
1342         (WebCore::RenderImage::imageChanged):
1343         (WebCore::RenderImage::notifyFinished):
1344         (WebCore::RenderImage::boxShadowShouldBeAppliedToBackground):
1345         (WebCore::RenderImage::computeBackgroundIsKnownToBeObscured):
1346         
1347             Use CachedImage::currentFrameKnownToBeOpaque which ensures that the frame is decoded and we get the real status.
1348             Tested by an additional case in fast/css/obscured-background-child-style-change.html.
1349
1350         * rendering/RenderImage.h:
1351         * rendering/RenderObject.cpp:
1352         (WebCore::RenderObject::styleWillChange):
1353         * rendering/RenderObject.h:
1354         (WebCore::RenderObject::hasBoxDecorations):
1355         (WebCore::RenderObject::computeBackgroundIsKnownToBeObscured):
1356         (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
1357         (RenderObjectBitfields):
1358         (WebCore::RenderObject::RenderObjectBitfields::boxDecorationState):
1359         (WebCore::RenderObject::RenderObjectBitfields::setBoxDecorationState):
1360         
1361             Combine box decoration bit and the obscuration status so we only need one extra bit.
1362
1363         (WebCore::RenderObject::setNeedsSimplifiedNormalFlowLayout):
1364         (WebCore::RenderObject::setHasBoxDecorations):
1365         (WebCore::RenderObject::invalidateBackgroundObscurationStatus):
1366         (WebCore::RenderObject::backgroundIsKnownToBeObscured):
1367         * rendering/RenderReplaced.cpp:
1368         (WebCore::RenderReplaced::layout):
1369
1370 2013-03-19  Dominic Mazzoni  <dmazzoni@google.com>
1371
1372         Implement Web Speech Synthesis for Chromium
1373         https://bugs.webkit.org/show_bug.cgi?id=111695
1374
1375         Reviewed by Adam Barth.
1376
1377         Straightforward implementation of speech synthesis
1378         for Chromium by exposing interfaces for the platform
1379         to implement.
1380
1381         * Modules/speech/SpeechSynthesis.cpp:
1382         (WebCore::SpeechSynthesis::boundaryEventOccurred):
1383         (WebCore::SpeechSynthesis::didStartSpeaking):
1384         (WebCore::SpeechSynthesis::didPauseSpeaking):
1385         (WebCore::SpeechSynthesis::didResumeSpeaking):
1386         (WebCore::SpeechSynthesis::didFinishSpeaking):
1387         (WebCore::SpeechSynthesis::speakingErrorOccurred):
1388         (WebCore):
1389         * Modules/speech/SpeechSynthesis.h:
1390         (SpeechSynthesis):
1391         * Modules/speech/SpeechSynthesisUtterance.cpp:
1392         (WebCore::SpeechSynthesisUtterance::SpeechSynthesisUtterance):
1393         (WebCore):
1394         (WebCore::SpeechSynthesisUtterance::~SpeechSynthesisUtterance):
1395         (WebCore::SpeechSynthesisUtterance::setVoice):
1396         * Modules/speech/SpeechSynthesisUtterance.h:
1397         (SpeechSynthesisUtterance):
1398         (WebCore::SpeechSynthesisUtterance::text):
1399         (WebCore::SpeechSynthesisUtterance::setText):
1400         (WebCore::SpeechSynthesisUtterance::lang):
1401         (WebCore::SpeechSynthesisUtterance::setLang):
1402         (WebCore::SpeechSynthesisUtterance::volume):
1403         (WebCore::SpeechSynthesisUtterance::setVolume):
1404         (WebCore::SpeechSynthesisUtterance::rate):
1405         (WebCore::SpeechSynthesisUtterance::setRate):
1406         (WebCore::SpeechSynthesisUtterance::pitch):
1407         (WebCore::SpeechSynthesisUtterance::setPitch):
1408         (WebCore::SpeechSynthesisUtterance::startTime):
1409         (WebCore::SpeechSynthesisUtterance::setStartTime):
1410         (WebCore::SpeechSynthesisUtterance::platformUtterance):
1411         * Modules/speech/SpeechSynthesisVoice.h:
1412         (WebCore::SpeechSynthesisVoice::~SpeechSynthesisVoice):
1413         * WebCore.exp.in:
1414         * WebCore.gypi:
1415         * platform/PlatformSpeechSynthesis.h:
1416         (PlatformSpeechSynthesis):
1417         * platform/PlatformSpeechSynthesisUtterance.cpp:
1418         (WebCore):
1419         (WebCore::PlatformSpeechSynthesisUtterance::create):
1420         * platform/PlatformSpeechSynthesisUtterance.h:
1421         (PlatformSpeechSynthesisUtterance):
1422         (WebCore::PlatformSpeechSynthesisUtterance::setClient):
1423         * platform/PlatformSpeechSynthesisVoice.cpp:
1424         (WebCore):
1425         (WebCore::PlatformSpeechSynthesisVoice::create):
1426         (WebCore::PlatformSpeechSynthesisVoice::PlatformSpeechSynthesisVoice):
1427         * platform/PlatformSpeechSynthesisVoice.h:
1428         (PlatformSpeechSynthesisVoice):
1429         (WebCore::PlatformSpeechSynthesisVoice::setVoiceURI):
1430         (WebCore::PlatformSpeechSynthesisVoice::setName):
1431         (WebCore::PlatformSpeechSynthesisVoice::setLang):
1432         (WebCore::PlatformSpeechSynthesisVoice::setLocalService):
1433         (WebCore::PlatformSpeechSynthesisVoice::setIsDefault):
1434         * platform/PlatformSpeechSynthesizer.cpp:
1435         (WebCore::PlatformSpeechSynthesizer::create):
1436         (WebCore::PlatformSpeechSynthesizer::setVoiceList):
1437         (WebCore):
1438         * platform/PlatformSpeechSynthesizer.h:
1439         (WebKit):
1440         (PlatformSpeechSynthesizerClient):
1441         (PlatformSpeechSynthesizer):
1442         * platform/chromium/PlatformSpeechSynthesizerChromium.cpp: Added.
1443         (WebCore):
1444         (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
1445         (WebCore::PlatformSpeechSynthesizer::~PlatformSpeechSynthesizer):
1446         (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
1447         (WebCore::PlatformSpeechSynthesizer::speak):
1448         (WebCore::PlatformSpeechSynthesizer::pause):
1449         (WebCore::PlatformSpeechSynthesizer::resume):
1450         (WebCore::PlatformSpeechSynthesizer::cancel):
1451         * platform/chromium/support/WebSpeechSynthesisUtterance.cpp: Added.
1452         (WebKit):
1453         (WebKit::WebSpeechSynthesisUtterance::WebSpeechSynthesisUtterance):
1454         (WebKit::WebSpeechSynthesisUtterance::operator=):
1455         (WebKit::WebSpeechSynthesisUtterance::assign):
1456         (WebKit::WebSpeechSynthesisUtterance::reset):
1457         (WebKit::WebSpeechSynthesisUtterance::operator PassRefPtr<PlatformSpeechSynthesisUtterance>):
1458         (WebKit::WebSpeechSynthesisUtterance::operator PlatformSpeechSynthesisUtterance*):
1459         (WebKit::WebSpeechSynthesisUtterance::text):
1460         (WebKit::WebSpeechSynthesisUtterance::lang):
1461         (WebKit::WebSpeechSynthesisUtterance::voice):
1462         (WebKit::WebSpeechSynthesisUtterance::volume):
1463         (WebKit::WebSpeechSynthesisUtterance::rate):
1464         (WebKit::WebSpeechSynthesisUtterance::pitch):
1465         (WebKit::WebSpeechSynthesisUtterance::startTime):
1466         * platform/chromium/support/WebSpeechSynthesisVoice.cpp: Added.
1467         (WebKit):
1468         (WebKit::WebSpeechSynthesisVoice::assign):
1469         (WebKit::WebSpeechSynthesisVoice::reset):
1470         (WebKit::WebSpeechSynthesisVoice::setVoiceURI):
1471         (WebKit::WebSpeechSynthesisVoice::setName):
1472         (WebKit::WebSpeechSynthesisVoice::setLanguage):
1473         (WebKit::WebSpeechSynthesisVoice::setIsLocalService):
1474         (WebKit::WebSpeechSynthesisVoice::setIsDefault):
1475         (WebKit::WebSpeechSynthesisVoice::operator PassRefPtr<WebCore::PlatformSpeechSynthesisVoice>):
1476         * platform/chromium/support/WebSpeechSynthesizerClientImpl.cpp: Added.
1477         (WebCore):
1478         (WebCore::WebSpeechSynthesizerClientImpl::WebSpeechSynthesizerClientImpl):
1479         (WebCore::WebSpeechSynthesizerClientImpl::~WebSpeechSynthesizerClientImpl):
1480         (WebCore::WebSpeechSynthesizerClientImpl::setVoiceList):
1481         (WebCore::WebSpeechSynthesizerClientImpl::didStartSpeaking):
1482         (WebCore::WebSpeechSynthesizerClientImpl::didFinishSpeaking):
1483         (WebCore::WebSpeechSynthesizerClientImpl::didPauseSpeaking):
1484         (WebCore::WebSpeechSynthesizerClientImpl::didResumeSpeaking):
1485         (WebCore::WebSpeechSynthesizerClientImpl::speakingErrorOccurred):
1486         (WebCore::WebSpeechSynthesizerClientImpl::wordBoundaryEventOccurred):
1487         (WebCore::WebSpeechSynthesizerClientImpl::sentenceBoundaryEventOccurred):
1488         * platform/chromium/support/WebSpeechSynthesizerClientImpl.h: Added.
1489         (WebCore):
1490         (WebSpeechSynthesizerClientImpl):
1491         * platform/mac/PlatformSpeechSynthesizerMac.mm:
1492         (-[WebSpeechSynthesisWrapper speakUtterance:WebCore::]):
1493         (-[WebSpeechSynthesisWrapper speechSynthesizer:didFinishSpeaking:]):
1494         (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
1495         (WebCore):
1496         (WebCore::PlatformSpeechSynthesizer::~PlatformSpeechSynthesizer):
1497         (WebCore::PlatformSpeechSynthesizer::speak):
1498         * platform/mock/PlatformSpeechSynthesizerMock.cpp:
1499         (WebCore::PlatformSpeechSynthesizerMock::PlatformSpeechSynthesizerMock):
1500         (WebCore::PlatformSpeechSynthesizerMock::speakingFinished):
1501         (WebCore::PlatformSpeechSynthesizerMock::speak):
1502         * platform/mock/PlatformSpeechSynthesizerMock.h:
1503         (PlatformSpeechSynthesizerMock):
1504
1505 2013-03-19  Ryosuke Niwa  <rniwa@webkit.org>
1506
1507         Another build fix after r146220.
1508
1509         * English.lproj/localizedStrings.js:
1510
1511 2013-03-19  Julien Chaffraix  <jchaffraix@webkit.org>
1512
1513         [CSS Grid Layout] Add parsing for grid-auto-{row|column}
1514         https://bugs.webkit.org/show_bug.cgi?id=112724
1515
1516         Reviewed by Tony Chang.
1517
1518         This change is a first step towards handling grid-auto-{row|column}.
1519         For now, only the parsing, storing and getComputedStyle bits are implemented.
1520         In order to do so without duplicating code, the functions handling <track-size>
1521         (named <track-minmax> in the code based on a previous version of the grammar)
1522         have been tweaked to be called in a standalone fashion. The code was also
1523         updated to match the grammar more closely:
1524         - <track-minmax> is now <track-size>.
1525         - <track-group> was renmoved, folded into <track-list>.
1526
1527         Test: fast/css-grid-layout/grid-auto-columns-rows-get-set.html
1528
1529         * css/CSSComputedStyleDeclaration.cpp:
1530         (WebCore::valueForGridTrackSize):
1531         Renamed from valueForGridTrackMinMax.
1532
1533         (WebCore::valueForGridTrackList):
1534         Folded valueForGridTrackGroup here.
1535
1536         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1537         * css/CSSParser.cpp:
1538         (WebCore::CSSParser::parseValue):
1539         Added the parsing for grid-auto-{rows|columns}.
1540
1541         (WebCore::CSSParser::parseGridTrackSize):
1542         Renamed from parseGridTrackMinMax. Changed to return the parsed value (or 0 in case of
1543         error). This enables us to reuse it in parseValue. Note that this function now moves
1544         the parser value list instead of the caller.
1545
1546         (WebCore::CSSParser::parseGridTrackList):
1547         Updated after parseGridTrackSize changes and parseGridTrackGroup removal.
1548
1549         * css/CSSParser.h: Updated the names.
1550         * css/CSSProperty.cpp:
1551         (WebCore::CSSProperty::isInheritedProperty):
1552         * css/CSSPropertyNames.in:
1553         Added the 2 new non-inherited properties.
1554
1555         * css/StyleResolver.cpp:
1556         (WebCore::createGridTrackSize):
1557         Renamed from createGridTrackMinMax. Also simplified to ensure code reuse (applyProperty hands
1558         down a CSSValue) and consistency (the state wasn't consistently the last argument).
1559
1560         (WebCore::createGridTrackList):
1561         Folded createGridTrackGroup into this function.
1562
1563         (WebCore::StyleResolver::applyProperty):
1564         Added the code for the new properties.
1565
1566         * rendering/style/RenderStyle.h:
1567         * rendering/style/StyleGridData.cpp:
1568         (WebCore::StyleGridData::StyleGridData):
1569         * rendering/style/StyleGridData.h:
1570         (WebCore::StyleGridData::operator==):
1571         Added the storage and boiler-plate code for the new properties.
1572
1573 2013-03-19  Geoffrey Garen  <ggaren@apple.com>
1574
1575         Removed a using declaration to avoid name conflicts
1576         https://bugs.webkit.org/show_bug.cgi?id=112752
1577
1578         Reviewed by Ryosuke Niwa.
1579
1580         * html/ClassList.cpp: Put the using declaration here instead.
1581
1582         * html/ClassList.h: Don't put a using declaration in this header because
1583         it can cause name conflicts with SVGNames.
1584
1585 2013-03-18  Ojan Vafai  <ojan@chromium.org>
1586
1587         Make intrinsic size keywords on flexboxes work
1588         https://bugs.webkit.org/show_bug.cgi?id=112652
1589
1590         Reviewed by Tony Chang.
1591
1592         Tests: fast/css-intrinsic-dimensions/intrinsic-sized-column-flex-items.html
1593                fast/css-intrinsic-dimensions/intrinsic-sized-flex-items.html
1594
1595         * platform/Length.h:
1596         (WebCore::Length::isSpecifiedOrIntrinsic):
1597         * rendering/RenderBox.cpp:
1598         (WebCore::RenderBox::constrainLogicalWidthInRegionByMinMax):
1599         (WebCore::RenderBox::computeLogicalWidthInRegion):
1600         (WebCore::RenderBox::computeLogicalWidthInRegionUsing):
1601         Pass in the Length so that RenderFlexibleBox can call this method and avoid
1602         doing a bunch of code duplication.
1603
1604         * rendering/RenderBox.h:
1605         * rendering/RenderFlexibleBox.cpp:
1606         (WebCore::RenderFlexibleBox::computeMainAxisExtentForChild):
1607         Instead of just calling valueForLength, call computeLogicalWidthInRegionUsing so that
1608         we properly resolve intrinsic Length types. Incidentally, this should also make viewport
1609         percentage units work.
1610
1611         (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax):
1612         Resolve intrinsic min/max Lengths. Also, instead of calling minPreferredLogicalWidth for the
1613         min-width: auto case, call computeMainAxisExtentForChild to correctly compute the min intrinsic size.
1614
1615 2013-03-19  Geoffrey Garen  <ggaren@apple.com>
1616
1617         Try to fix the Windows build.
1618
1619         * svg/SVGAnimateMotionElement.cpp:
1620         (WebCore::SVGAnimateMotionElement::hasValidAttributeType): Qualify the
1621         namespace to avoid conflicts.
1622
1623 2013-03-19  Ryosuke Niwa  <rniwa@webkit.org>
1624
1625         Windows build fix after r146264.
1626
1627         * svg/SVGAnimateMotionElement.cpp:
1628         (WebCore::SVGAnimateMotionElement::hasValidAttributeType):
1629
1630 2013-03-19  Nate Chapin  <japhet@chromium.org>
1631
1632         REGRESSION(r146223): chromium asserts/crashes in DocumentLoader
1633         https://bugs.webkit.org/show_bug.cgi?id=112745
1634
1635         Reviewed by Kenneth Russell.
1636
1637         Fixes layout tests on chromium debug
1638
1639         * loader/DocumentLoader.cpp:
1640         (WebCore::DocumentLoader::mainReceivedError): Frame might be detached, get
1641             defersLoading() from mainResourceLoader().
1642         (WebCore::DocumentLoader::responseReceived): RefPtr got dropped, it's really needed.
1643         (WebCore::DocumentLoader::receivedData): Frame might be detached, get
1644             defersLoading() from mainResourceLoader().
1645         (WebCore::DocumentLoader::cancelMainResourceLoad): The ResourceError parameter
1646             can be null if coming from the WebKit layer, we should have a default just in case.
1647
1648 2013-03-19  Geoffrey Garen  <ggaren@apple.com>
1649
1650         Refactored script content removal in the fragment parser for clarity and speed
1651         https://bugs.webkit.org/show_bug.cgi?id=112734
1652
1653         Reviewed by Enrica Casucci.
1654
1655         * WebCore.exp.in: Export!
1656
1657         * dom/DocumentFragment.cpp:
1658         (WebCore::DocumentFragment::parseHTML):
1659         (WebCore::DocumentFragment::parseXML):
1660         * dom/DocumentFragment.h:
1661         (DocumentFragment): Updated for rename of FragmentScriptingPermission to
1662         ParserContentPolicy.
1663
1664         * dom/Element.cpp:
1665         (WebCore::isEventHandlerAttribute):
1666         (WebCore::Element::isJavaScriptURLAttribute):
1667         (WebCore::Element::isJavaScriptAttribute): Fixed a FIXME by factoring
1668         out some helper functions that reuse isURLAttribute(). This makes our
1669         attribute removal slightly more precise, as reflected in test changes.
1670
1671         (WebCore::Element::stripJavaScriptAttributes): Factored this function out
1672         of parserSetAttributes to clarify that the parser is responsible for
1673         fully removing scripts before inserting anything into the DOM.
1674
1675         Now that this is a helper function, we can avoid doing any work in the
1676         common case, where script content is allowed. Also, when we do have to
1677         strip attributes, we use "two finger compaction" to avoid copying the
1678         vector, and to avoid O(N) vector removal operations when there is
1679         something to remove.
1680
1681         (WebCore::Element::parserSetAttributes):
1682         * dom/Element.h:
1683
1684         * dom/FragmentScriptingPermission.h:
1685         (WebCore::scriptingContentIsAllowed):
1686         (WebCore::disallowScriptingContent):
1687         (WebCore::pluginContentIsAllowed):
1688         (WebCore::allowPluginContent): Renamed for clarity, and added some helper
1689         functions for reading values out of this enum.
1690
1691         * dom/ScriptableDocumentParser.cpp:
1692         (WebCore::ScriptableDocumentParser::ScriptableDocumentParser): Moved
1693         a settings check into the parser constructor so we're sure that all
1694         clients get the right behavior.
1695
1696         * dom/ScriptableDocumentParser.h:
1697         (WebCore::ScriptableDocumentParser::parserContentPolicy):
1698         (ScriptableDocumentParser):
1699         * editing/markup.cpp:
1700         (WebCore::createFragmentFromMarkup):
1701         (WebCore::createFragmentFromMarkupWithContext):
1702         (WebCore::createFragmentForInnerOuterHTML):
1703         (WebCore::createContextualFragment):
1704         * editing/markup.h: Updated for renames.
1705
1706         * html/HTMLAnchorElement.cpp:
1707         (WebCore::HTMLAnchorElement::isURLAttribute): Fixed a bug where
1708         isURLAttribute would ignore href attributes in other namespaces, like
1709         xlink:href.
1710
1711         * html/HTMLBaseElement.cpp:
1712         (WebCore::HTMLBaseElement::isURLAttribute): Same bug.
1713
1714         * html/HTMLElement.cpp:
1715         (WebCore::HTMLElement::isURLAttribute): Fixed a logic error where HTMLElement
1716         wouldn't call through to its base class.
1717
1718         * html/HTMLLinkElement.cpp:
1719         (WebCore::HTMLLinkElement::isURLAttribute): Same isURLAttribute namespace
1720         bug as above.
1721
1722         * html/parser/HTMLConstructionSite.cpp:
1723         (WebCore::setAttributes): Helper function for optionally stripping
1724         disallowed attributes before setting them on an element. This helps all
1725         clients get the right behavior without sprinkling checks everywhere.
1726
1727         (WebCore::HTMLConstructionSite::HTMLConstructionSite):
1728         (WebCore::HTMLConstructionSite::insertHTMLHtmlStartTagBeforeHTML):
1729
1730         (WebCore::HTMLConstructionSite::insertScriptElement): Don't schedule the
1731         element for insertion into the document if the element is forbidden. This
1732         is slightly clearer than leaving an empty forbidden element in the document.
1733
1734         (WebCore::HTMLConstructionSite::createElement):
1735         (WebCore::HTMLConstructionSite::createHTMLElement):
1736         * html/parser/HTMLConstructionSite.h:
1737         (HTMLConstructionSite):
1738         (WebCore::HTMLConstructionSite::parserContentPolicy):
1739         * html/parser/HTMLDocumentParser.cpp:
1740         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
1741         (WebCore::HTMLDocumentParser::runScriptsForPausedTreeBuilder):
1742         (WebCore::HTMLDocumentParser::parseDocumentFragment):
1743         * html/parser/HTMLDocumentParser.h:
1744         (HTMLDocumentParser):
1745         (WebCore::HTMLDocumentParser::create):
1746         * html/parser/HTMLTreeBuilder.cpp:
1747         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
1748         (WebCore::HTMLTreeBuilder::FragmentParsingContext::FragmentParsingContext):
1749         Updated for renames and interface changes above.
1750
1751         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
1752         (WebCore::HTMLTreeBuilder::processEndTag): Removed isParsingFragment()
1753         checks to make it possible to use ParserContentPolicy in more places.
1754
1755         Removed call to removeChildren() because, if an element is forbidden,
1756         we fully remove the element now. This brings behavior for <script>
1757         elements in line with behavior for plug-in elements. It also brings
1758         behavior of the HTML parser in line with behavior of the XML parser.
1759
1760         * html/parser/HTMLTreeBuilder.h:
1761         (WebCore::HTMLTreeBuilder::create):
1762         (FragmentParsingContext):
1763         (WebCore::HTMLTreeBuilder::FragmentParsingContext::contextElement):
1764         * platform/blackberry/PasteboardBlackBerry.cpp:
1765         (WebCore::Pasteboard::documentFragment):
1766         * platform/chromium/DragDataChromium.cpp:
1767         (WebCore::DragData::asFragment):
1768         * platform/chromium/PasteboardChromium.cpp:
1769         (WebCore::Pasteboard::documentFragment):
1770         * platform/gtk/PasteboardGtk.cpp:
1771         (WebCore::Pasteboard::documentFragment):
1772         * platform/mac/PasteboardMac.mm:
1773         (WebCore::Pasteboard::documentFragment):
1774         * platform/qt/DragDataQt.cpp:
1775         (WebCore::DragData::asFragment):
1776         * platform/qt/PasteboardQt.cpp:
1777         (WebCore::Pasteboard::documentFragment):
1778         * platform/win/ClipboardUtilitiesWin.cpp:
1779         (WebCore::fragmentFromCFHTML):
1780         (WebCore::fragmentFromHTML):
1781         * platform/wx/PasteboardWx.cpp:
1782         (WebCore::Pasteboard::documentFragment): Updated for renames and interface
1783         changes.
1784
1785         * svg/SVGAElement.cpp:
1786         (WebCore::SVGAElement::isURLAttribute): Fixed a bug where SVG anchor
1787         elements didn't identify their URL attributes.
1788
1789         * svg/SVGAElement.h:
1790         (SVGAElement):
1791
1792         * xml/XMLErrors.cpp:
1793         (WebCore::createXHTMLParserErrorHeader):
1794         (WebCore::XMLErrors::insertErrorMessageBlock): No need to disallow
1795         scripting attributes here because we're creating the attributes 
1796         ourselves and we know they're not scripting attributes.
1797
1798         * xml/parser/XMLDocumentParser.cpp:
1799         (WebCore::XMLDocumentParser::parseDocumentFragment):
1800         * xml/parser/XMLDocumentParser.h:
1801         (WebCore::XMLDocumentParser::create):
1802         (XMLDocumentParser): Updated for renames and interface changes above.
1803
1804         Removed the 8 inline capacity in the attribute vector so we could share
1805         helper functions with the HTML parser, which didn't have it.
1806
1807         * xml/parser/XMLDocumentParserLibxml2.cpp:
1808         (WebCore::setAttributes):
1809         (WebCore):
1810         (WebCore::XMLDocumentParser::XMLDocumentParser):
1811         (WebCore::handleNamespaceAttributes):
1812         (WebCore::handleElementAttributes):
1813         (WebCore::XMLDocumentParser::startElementNs):
1814         (WebCore::XMLDocumentParser::endElementNs):
1815         * xml/parser/XMLDocumentParserQt.cpp:
1816         (WebCore::setAttributes):
1817         (WebCore):
1818         (WebCore::XMLDocumentParser::XMLDocumentParser):
1819         (WebCore::handleNamespaceAttributes):
1820         (WebCore::handleElementAttributes):
1821         (WebCore::XMLDocumentParser::parseStartElement):
1822         (WebCore::XMLDocumentParser::parseEndElement): Same changes as for the
1823         HTML parser.
1824
1825 2013-03-19  Philip Rogers  <pdr@google.com>
1826
1827         Clean up static_casts for SVG renderers
1828         https://bugs.webkit.org/show_bug.cgi?id=111651
1829
1830         Reviewed by Abhishek Arya.
1831
1832         toRenderSVGPath and toRenderSVGFilter are preferred over static_casts because bad casts can
1833         be caught on our testing infrastructure. This patch replaces all static_casts for
1834         RenderSVGPath and RenderSVGFilter with toRenderSVGPath and toRenderSVGFilter, respectively.
1835
1836         This patch also adds FIXME to the remaining toRenderSVG* instances that are missing.
1837
1838         No new tests as this is covered with existing tests.
1839
1840         * rendering/RenderLayer.cpp:
1841         (WebCore::RenderLayer::paintLayerContents):
1842
1843             This call is currently safe due to the element->hasTagName(SVGNames::clipPathTag) check.
1844
1845         * rendering/svg/RenderSVGPath.h:
1846         (WebCore):
1847         (WebCore::toRenderSVGPath):
1848         * rendering/svg/RenderSVGResourceFilter.h:
1849         (WebCore):
1850         (WebCore::toRenderSVGFilter):
1851         * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
1852         (WebCore::RenderSVGResourceFilterPrimitive::styleDidChange):
1853         * rendering/svg/RenderSVGRoot.cpp:
1854         (WebCore::RenderSVGRoot::addResourceForClientInvalidation):
1855         * rendering/svg/SVGRenderSupport.cpp:
1856         (WebCore::SVGRenderSupport::repaintRectForRendererInLocalCoordinatesExcludingSVGShadow):
1857         (WebCore::SVGRenderSupport::rendererHasSVGShadow):
1858         (WebCore::SVGRenderSupport::setRendererHasSVGShadow):
1859         * rendering/svg/SVGRenderingContext.cpp:
1860         (WebCore::SVGRenderingContext::~SVGRenderingContext):
1861
1862             This cast was not correct! Thankfully it was not required anyway.
1863
1864         * svg/SVGCircleElement.cpp:
1865         (WebCore::SVGCircleElement::svgAttributeChanged):
1866
1867             This cast was not correct!
1868
1869         * svg/SVGEllipseElement.cpp:
1870         (WebCore::SVGEllipseElement::svgAttributeChanged):
1871
1872             This cast was not correct!
1873
1874         * svg/SVGLineElement.cpp:
1875         (WebCore::SVGLineElement::svgAttributeChanged):
1876         * svg/SVGPathElement.cpp:
1877         (WebCore::SVGPathElement::svgAttributeChanged):
1878         (WebCore::SVGPathElement::pathSegListChanged):
1879         (WebCore::SVGPathElement::getBBox):
1880         * svg/SVGPolyElement.cpp:
1881         (WebCore::SVGPolyElement::svgAttributeChanged):
1882         * svg/SVGRectElement.cpp:
1883         (WebCore::SVGRectElement::svgAttributeChanged):
1884
1885 2013-03-19  Beth Dakin  <bdakin@apple.com>
1886
1887         RenderLayer::scrollTo() should call FrameLoaderClient::didChangeScrollOffset()
1888         https://bugs.webkit.org/show_bug.cgi?id=110673
1889
1890         Reviewed by Simon Fraser.
1891
1892         FrameLoaderClient::didChangeScrollOffset() should be called whenever something is 
1893         actually being scrolled. 
1894
1895         * rendering/RenderLayer.cpp:
1896         (WebCore::RenderLayer::scrollTo):
1897
1898 2013-03-19  Marja Hölttä  <marja@chromium.org>
1899
1900         [V8] Add machinery for generating specialized bindings for the main world
1901         https://bugs.webkit.org/show_bug.cgi?id=111417
1902
1903         Reviewed by Jochen Eisinger.
1904
1905         The new specialized bindings will be faster, because they don't need to
1906         do the "main world, isolated world or a worker" check, but can right
1907         away assume that we're in the main world.
1908
1909         Added an IDL attribute (V8PerWorldBindings) to define which
1910         attribute getters / setters to specialize.
1911
1912         This patch generates main world bindings for getters and setters of Node
1913         and Element. (The possibility to generate bindings for callbacks will be
1914         added later.)
1915
1916         No new tests (updated existing bindings tests).
1917
1918         * bindings/scripts/CodeGeneratorV8.pm:
1919         (GenerateHeader):
1920         (GenerateNormalAttrGetterCallback):
1921         (GenerateNormalAttrGetter):
1922         (GenerateNormalAttrSetterCallback):
1923         (GenerateNormalAttrSetter):
1924         (GenerateNamedConstructor):
1925         (GenerateSingleBatchedAttribute):
1926         (GenerateImplementation):
1927         (GenerateCallbackImplementation):
1928         (GenerateFunctionCallString):
1929         (CreateCustomSignature):
1930         (NativeToJSValue):
1931         * bindings/scripts/IDLAttributes.txt:
1932         * bindings/scripts/test/V8/V8Float64Array.cpp:
1933         (WebCore::ConfigureV8Float64ArrayTemplate):
1934         (WebCore::V8Float64Array::GetTemplate):
1935         (WebCore::V8Float64Array::HasInstance):
1936         * bindings/scripts/test/V8/V8Float64Array.h:
1937         (WebCore::toV8ForMainWorld):
1938         (WebCore):
1939         (WebCore::toV8FastForMainWorld):
1940         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1941         (WebCore):
1942         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
1943         (WebCore::V8TestActiveDOMObject::GetTemplate):
1944         (WebCore::V8TestActiveDOMObject::HasInstance):
1945         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
1946         (WebCore::toV8ForMainWorld):
1947         (WebCore):
1948         (WebCore::toV8FastForMainWorld):
1949         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1950         (WebCore::ConfigureV8TestCustomNamedGetterTemplate):
1951         (WebCore::V8TestCustomNamedGetter::GetTemplate):
1952         (WebCore::V8TestCustomNamedGetter::HasInstance):
1953         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
1954         (WebCore::toV8ForMainWorld):
1955         (WebCore):
1956         (WebCore::toV8FastForMainWorld):
1957         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1958         (WebCore):
1959         (WebCore::ConfigureV8TestEventConstructorTemplate):
1960         (WebCore::V8TestEventConstructor::GetTemplate):
1961         (WebCore::V8TestEventConstructor::HasInstance):
1962         * bindings/scripts/test/V8/V8TestEventConstructor.h:
1963         (WebCore::toV8ForMainWorld):
1964         (WebCore):
1965         (WebCore::toV8FastForMainWorld):
1966         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1967         (WebCore::ConfigureV8TestEventTargetTemplate):
1968         (WebCore::V8TestEventTarget::GetTemplate):
1969         (WebCore::V8TestEventTarget::HasInstance):
1970         * bindings/scripts/test/V8/V8TestEventTarget.h:
1971         (WebCore::toV8ForMainWorld):
1972         (WebCore):
1973         (WebCore::toV8FastForMainWorld):
1974         * bindings/scripts/test/V8/V8TestException.cpp:
1975         (WebCore):
1976         (WebCore::ConfigureV8TestExceptionTemplate):
1977         (WebCore::V8TestException::GetTemplate):
1978         (WebCore::V8TestException::HasInstance):
1979         * bindings/scripts/test/V8/V8TestException.h:
1980         (WebCore::toV8ForMainWorld):
1981         (WebCore):
1982         (WebCore::toV8FastForMainWorld):
1983         * bindings/scripts/test/V8/V8TestInterface.cpp:
1984         (WebCore):
1985         (WebCore::ConfigureV8TestInterfaceTemplate):
1986         (WebCore::V8TestInterface::GetTemplate):
1987         (WebCore::V8TestInterface::HasInstance):
1988         * bindings/scripts/test/V8/V8TestInterface.h:
1989         (WebCore::toV8ForMainWorld):
1990         (WebCore):
1991         (WebCore::toV8FastForMainWorld):
1992         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1993         (WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
1994         (WebCore::V8TestMediaQueryListListener::GetTemplate):
1995         (WebCore::V8TestMediaQueryListListener::HasInstance):
1996         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1997         (WebCore::toV8ForMainWorld):
1998         (WebCore):
1999         (WebCore::toV8FastForMainWorld):
2000         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2001         (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
2002         (WebCore::ConfigureV8TestNamedConstructorTemplate):
2003         (WebCore::V8TestNamedConstructor::GetTemplate):
2004         (WebCore::V8TestNamedConstructor::HasInstance):
2005         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2006         (WebCore::toV8ForMainWorld):
2007         (WebCore):
2008         (WebCore::toV8FastForMainWorld):
2009         * bindings/scripts/test/V8/V8TestNode.cpp:
2010         (WebCore::ConfigureV8TestNodeTemplate):
2011         (WebCore::V8TestNode::GetTemplate):
2012         (WebCore::V8TestNode::HasInstance):
2013         * bindings/scripts/test/V8/V8TestNode.h:
2014         (WebCore::toV8ForMainWorld):
2015         (WebCore):
2016         (WebCore::toV8FastForMainWorld):
2017         * bindings/scripts/test/V8/V8TestObj.cpp:
2018         (WebCore):
2019         (WebCore::ConfigureV8TestObjTemplate):
2020         (WebCore::V8TestObj::GetTemplate):
2021         (WebCore::V8TestObj::HasInstance):
2022         (WebCore::V8TestObj::installPerContextProperties):
2023         * bindings/scripts/test/V8/V8TestObj.h:
2024         (WebCore::toV8ForMainWorld):
2025         (WebCore):
2026         (WebCore::toV8FastForMainWorld):
2027         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
2028         (WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
2029         (WebCore::V8TestOverloadedConstructors::GetTemplate):
2030         (WebCore::V8TestOverloadedConstructors::HasInstance):
2031         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
2032         (WebCore::toV8ForMainWorld):
2033         (WebCore):
2034         (WebCore::toV8FastForMainWorld):
2035         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2036         (WebCore):
2037         (WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
2038         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
2039         (WebCore::V8TestSerializedScriptValueInterface::HasInstance):
2040         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2041         (WebCore::toV8ForMainWorld):
2042         (WebCore):
2043         (WebCore::toV8FastForMainWorld):
2044         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
2045         (WebCore):
2046         (WebCore::ConfigureV8TestTypedefsTemplate):
2047         (WebCore::V8TestTypedefs::GetTemplate):
2048         (WebCore::V8TestTypedefs::HasInstance):
2049         * bindings/scripts/test/V8/V8TestTypedefs.h:
2050         (WebCore::toV8ForMainWorld):
2051         (WebCore):
2052         (WebCore::toV8FastForMainWorld):
2053         * bindings/v8/DOMDataStore.h:
2054         (WebCore::DOMDataStore::getWrapperForMainWorld):
2055         (DOMDataStore):
2056         * bindings/v8/V8DOMConfiguration.cpp:
2057         (WebCore::V8DOMConfiguration::batchConfigureAttributes):
2058         (WebCore::V8DOMConfiguration::configureTemplate):
2059         * bindings/v8/V8DOMConfiguration.h:
2060         (BatchedAttribute):
2061         (V8DOMConfiguration):
2062         (WebCore::V8DOMConfiguration::configureAttribute):
2063         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2064         (WebCore::toV8ForMainWorld):
2065         (WebCore):
2066         * bindings/v8/custom/V8EventTargetCustom.cpp:
2067         (WebCore::toV8ForMainWorld):
2068         (WebCore):
2069         * bindings/v8/custom/V8IDBAnyCustom.cpp:
2070         (WebCore::toV8ForMainWorld):
2071         (WebCore):
2072         * bindings/v8/custom/V8MicroDataItemValueCustom.cpp:
2073         (WebCore::toV8ForMainWorld):
2074         (WebCore):
2075         * bindings/v8/custom/V8WorkerContextCustom.cpp:
2076         (WebCore::toV8ForMainWorld):
2077         (WebCore):
2078         * dom/Element.idl:
2079         * dom/Node.idl:
2080
2081 2013-03-19  Mike West  <mkwst@chromium.org>
2082
2083         FeatureObserver: Measure X-Frame-Options usage.
2084         https://bugs.webkit.org/show_bug.cgi?id=112670
2085
2086         Reviewed by Adam Barth.
2087
2088         This patch adds three FeatureObserver entries to gather information
2089         about 'X-Frame-Options' usage in general, and in particular usage
2090         and potential misunderstanding of the 'SAMEORIGIN' value.
2091
2092         Three entries are added:
2093
2094         - XFrameOptions measures the raw number of 'X-Frame-Options' headers.
2095
2096         - XFrameOptionsSameOrigin measures the number of those headers that
2097           set the value to 'SAMEORIGIN'.
2098
2099         - XFrameOptionsSameOriginWithBadAncestorChain measures the number of
2100           occasions in which the frame passed the "top-only" origin check we're
2101           currently performing, but would have failed a more strict check
2102           against poisoned ancestor chains (that is, an ancestor chain that
2103           looks like 'example.com' -> 'evil.com' -> 'example.com').
2104
2105         Mozilla is considering changing 'SAMEORIGIN's behavior to block the
2106         latter loophole[1], and the UI Safety spec is considering dropping
2107         'top-only' entirely[2]. This data will inform those decisions.
2108
2109         [1]: https://bugzilla.mozilla.org/show_bug.cgi?id=725490
2110         [2]: http://lists.w3.org/Archives/Public/public-webappsec/2013Mar/0007.html
2111
2112         This doesn't change web-visible behavior; it only adds histograms
2113
2114         * loader/FrameLoader.cpp:
2115         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
2116             When processing an 'X-Frame-Options' header's value, call out to
2117             FeatureObserver when relevant to increment the correct histogram
2118             entries.
2119         * page/FeatureObserver.h:
2120             Added three entries to the FeatureObserver enum: XFrameOptions,
2121             XFrameOptionsSameOrigin, and XFrameOptionsSameOriginWithBadAncestorChain.
2122             Each is explained above.
2123
2124 2013-03-19  Adam Barth  <abarth@webkit.org>
2125
2126         GenerateHashValue should be usable outside CodeGeneratorJS.pm
2127         https://bugs.webkit.org/show_bug.cgi?id=112736
2128
2129         Reviewed by Benjamin Poulain.
2130
2131         GenerateHashValue is not specific to CodeGeneratorJS.pm. Instead, the
2132         function matches the StringHash used in WTF. This patch moves the
2133         function into a separate Perl module so that it can be used by other
2134         Perl scripts. For example, I plan to use this function to compute the
2135         hash value for HTMLNames at compile time rather than at startup.
2136
2137         * bindings/scripts/CodeGeneratorJS.pm:
2138         (GenerateHashTable):
2139         * bindings/scripts/Hash.pm: Added.
2140         (leftShift):
2141         (GenerateHashValue):
2142
2143 2013-03-19  Dean Jackson  <dino@apple.com>
2144
2145         Allow PlugIn Snapshotting to be tested
2146         https://bugs.webkit.org/show_bug.cgi?id=98696
2147
2148         Reviewed by Tim Horton.
2149
2150         Expose a new setting maximumPlugInSnapshotAttempts that can
2151         be set by testing scripts.
2152
2153         Tests: plugins/snapshotting/restart.html
2154                plugins/snapshotting/simple.html
2155
2156         * page/Settings.in:
2157
2158 2013-03-19  Dean Jackson  <dino@apple.com>
2159
2160         Restarting a snapshotted plugin should restart all plugins from the same domain on the page
2161         https://bugs.webkit.org/show_bug.cgi?id=112725
2162
2163         Reviewed by Tim Horton.
2164
2165         If the user restarts a snapshotted plugin, then typically they will
2166         want to restart all similar plugins on the page, where similarity
2167         is defined by the domain of the content. Or in other words, since clients
2168         will typically add a restarted plugin to the list of autostarting
2169         domain hashes, we should start the other plugins that would autostart
2170         on reload.
2171
2172         When a snapshotted plugin gets the user click telling it to restart, it iterates
2173         over every frame in the document looking for domain hashes similar to its own.
2174         It then manually restarts each of the paused plugins.
2175
2176         * html/HTMLPlugInImageElement.cpp:
2177         (WebCore::addPlugInsFromNodeListMatchingOriginHash): Static helper function
2178             that builds a list of plugins to restart.
2179         (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): After restarting itself,
2180             the plugin looks for all other similar snapshotted plugins in the page.
2181         (WebCore::HTMLPlugInImageElement::restartSnapshottedPlugIn): Splits out the actual
2182             restart functionality, to make it separate from plugins that were manually
2183             restarted and thus probably want to forward a delayed click event.
2184         * html/HTMLPlugInImageElement.h:
2185         (HTMLPlugInImageElement): New method restartSnapshottedPlugIn.
2186
2187 2013-03-19  Nate Chapin  <japhet@chromium.org>
2188
2189         Merge MainResourceLoader's SubstituteData loading + others into DocumentLoader
2190         https://bugs.webkit.org/show_bug.cgi?id=112722
2191
2192         Part of the ongoing effort to merge MainResourceLoader entirely
2193         into DocumentLoader.
2194
2195         Reviewed by Antti Koivisto.
2196
2197         No new tests, refactor only.
2198
2199         * loader/DocumentLoader.cpp:
2200         (WebCore::DocumentLoader::mainReceivedError): Moved from MainResourceLoader::receivedError
2201             and the failure case in MainResourceLoader::notifyFinished.
2202         (WebCore::DocumentLoader::stopLoading):
2203         (WebCore::DocumentLoader::finishedLoading):
2204         (WebCore::DocumentLoader::handleSubstituteDataLoadNow): Moved from MainResourceLoader.
2205         (WebCore::DocumentLoader::startDataLoadTimer): Moved from MainResourceLoader.
2206         (WebCore::DocumentLoader::handleSubstituteDataLoadSoon): Moved from MainResourceLoader.
2207         (WebCore::DocumentLoader::willSendRequest):
2208         (WebCore::DocumentLoader::continueAfterNavigationPolicy):
2209         (WebCore::DocumentLoader::responseReceived):
2210         (WebCore::DocumentLoader::receivedData):
2211         (WebCore::DocumentLoader::startLoadingMainResource): Most of MainResourceLoader::load
2212             moved here.
2213         (WebCore::DocumentLoader::cancelMainResourceLoad): MainResourceLoader::cancel
2214             moved here.
2215         * loader/DocumentLoader.h:
2216         * loader/MainResourceLoader.cpp:
2217         (WebCore::MainResourceLoader::notifyFinished):
2218         (WebCore::MainResourceLoader::reportMemoryUsage):
2219         (WebCore::MainResourceLoader::load):
2220         (WebCore::MainResourceLoader::identifier):
2221         * loader/MainResourceLoader.h:
2222
2223 2013-03-19  Ryosuke Niwa  <rniwa@webkit.org>
2224
2225         Unreviewed build fix after r146220. Add the missing ]'s.
2226
2227         * English.lproj/localizedStrings.js:
2228
2229 2013-03-19  Alpha Lam  <hclam@chromium.org>
2230
2231         GIFImageReader to count frames and decode in one pass
2232         https://bugs.webkit.org/show_bug.cgi?id=111144
2233
2234         Reviewed by Stephen White.
2235
2236         OBJECTIVE
2237
2238         This change has the objective of improving performance reading GIF
2239         files. This implementation can parse the entire GIF file in one pass
2240         and saves information about each frame, such that decoding in a later
2241         pass does not need to parse the file again.
2242
2243         This change fixes the performance problem of decoding GIF files when
2244         they are received very slowly. Existing implementation creates a new
2245         GIFImageReader for counting frames for every time it is notified that
2246         new data has been received, this has O(n^2) behavior when data is
2247         received very slowly.
2248
2249         ALGORITHM
2250
2251         This implementation divides the decoding process into two separate
2252         steps: parse and LZW decoding.
2253
2254         In the parse step, the state machine is similar to the existing
2255         implementation. However this algorithm does not perform any decoding
2256         while scanning through the file. Intead it creates a new data structure
2257         for caching all frame information and the corresponding LZW blocks.
2258
2259         If a full decode is requested then LZW decoding is performed. This
2260         implementation looks through all frame information saved and decodes
2261         each frame sequentially until the target frame is reached.
2262
2263         Because of the separation of parse and decode, each frame can be
2264         decoded separately. This paves the way to support seeking in GIF files.
2265
2266         TESTING
2267
2268         Added a new unit test to cover progressively decoding a GIF image.
2269         There are already GIF unit tests for functional testing.
2270         Exhaustive testing was done locally with a corpus of 60k images.
2271         I mixed the corpus with some generated bad data and truncated files.
2272         The results was bit-identical when compared to the previous
2273         implementation.
2274
2275         These was also no crashing when decoding the entire corpus.
2276
2277         * platform/image-decoders/gif/GIFImageDecoder.cpp:
2278         (WebCore::GIFImageDecoder::GIFImageDecoder):
2279         (WebCore::GIFImageDecoder::setData):
2280         (WebCore::GIFImageDecoder::frameCount):
2281         (WebCore::GIFImageDecoder::repetitionCount):
2282         (WebCore::GIFImageDecoder::decode):
2283         * platform/image-decoders/gif/GIFImageDecoder.h:
2284         (GIFImageDecoder):
2285         * platform/image-decoders/gif/GIFImageReader.cpp:
2286         (GIFLZWContext::outputRow):
2287         (GIFLZWContext::doLZW):
2288         (GIFFrameContext::decode):
2289         (GIFImageReader::decode):
2290         (GIFImageReader::parse):
2291         (GIFImageReader::addFrameIfNecessary):
2292         (GIFLZWContext::prepareToDecode):
2293         * platform/image-decoders/gif/GIFImageReader.h:
2294         There is a lot of reshuffling in GIFLZWContext and GIFFrameContext.
2295         These changes has the goal of having GIFLZWContext be a pure decoding
2296         state machine. GIFFrameContext is mostly a read-only container for
2297         frame information. With all these changes we can decode each
2298         GIFFrameContext independently.
2299
2300         The ownership pattern is:
2301         GIFImageReader owns GIFFrameContext owns GIFLZWContext.
2302
2303         (GIFLZWContext::GIFLZWContext):
2304         (GIFLZWContext):
2305         (GIFLZWContext::hasRemainingRows):
2306         GIFLZWContext is moved to the top of file.
2307         (GIFLZWBlock):
2308         (GIFLZWBlock::GIFLZWBlock):
2309         New data structure to save block position and size.
2310         (GIFFrameContext):
2311         (GIFFrameContext::GIFFrameContext):
2312         (GIFFrameContext::~GIFFrameContext):
2313         (GIFFrameContext::addLzwBlock):
2314         (GIFFrameContext::isComplete):
2315         (GIFFrameContext::isHeaderDefined):
2316         (GIFFrameContext::isDataSizeDefined):
2317         (GIFFrameContext::setComplete):
2318         (GIFFrameContext::setHeaderDefined):
2319         (GIFFrameContext::setDataSize):
2320         Now owns GIFLZWContext for decoding.
2321         (GIFImageReader::GIFImageReader):
2322         (GIFImageReader::~GIFImageReader):
2323         (GIFImageReader::imagesCount):
2324         (GIFImageReader::frameContext):
2325         (GIFImageReader):
2326         (GIFImageReader::parseFailed):
2327         (GIFImageReader::isFirstFrame):
2328         Owns a list of GIFFrameContxt.
2329
2330 2013-03-19  Brent Fulgham  <bfulgham@webkit.org>
2331
2332         [WinCairo] Unreviewed build correction for WebCore library.
2333
2334         * WebCore.vcxproj/WebCore.vcxproj: Exclude CG-specific frame source
2335         from WinCairo build.
2336         * WebCore.vcxproj/WebCoreGeneratedWinCairo.make: Pass correct
2337         parameter to build-generated-files.sh for WinCairo build.
2338
2339 2013-03-19  Leon Scroggins  <scroggo@chromium.org>
2340
2341         Implement onRefEncodedData for lazy pixel refs.
2342         This allows printToSkPicture to write the original
2343         encoded data to the stream.
2344         Add a method to ImageFrameGenerator to copy its
2345         data, which is used by onRefEncodedData.
2346         https://bugs.webkit.org/show_bug.cgi?id=110759
2347
2348         Reviewed by Stephen White.
2349
2350         No new tests. New functionality is for testing purposes
2351         (creating SKP files).
2352
2353         * platform/graphics/chromium/ImageFrameGenerator.cpp:
2354         (WebCore::ImageFrameGenerator::data):
2355         (WebCore):
2356         * platform/graphics/chromium/ImageFrameGenerator.h:
2357         (ImageFrameGenerator):
2358         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
2359         (WebCore::LazyDecodingPixelRef::isClipped):
2360         (WebCore):
2361         (WebCore::LazyDecodingPixelRef::onRefEncodedData):
2362         * platform/graphics/chromium/LazyDecodingPixelRef.h:
2363         (LazyDecodingPixelRef):
2364
2365 2013-03-19  Philip Rogers  <pdr@google.com>
2366
2367         Separate SVG image size and container size
2368         https://bugs.webkit.org/show_bug.cgi?id=112651
2369
2370         Reviewed by Stephen Chenney.
2371
2372         Previously, SVG images could retain their cached size between reloads due to a bug where an
2373         old container size would be re-used if the image's new container size was not available yet.
2374
2375         This patch changes SVGImage::size() to return the intrinsic size of the image before a
2376         container size has been set. SVGImageCache::imageSizeForRenderer will now return the
2377         image's intrinsic size instead of a cached value if the container size cannot be looked up.
2378         In javascript, querying [SVGImage].width will now return either the image's intrinsic size
2379         or the size of 'imageForContainer'.
2380
2381         Test: svg/as-image/svg-container-size-after-reload.html
2382
2383         * svg/graphics/SVGImage.cpp:
2384         (WebCore::SVGImage::setContainerSize):
2385         (WebCore::SVGImage::containerSize):
2386         (WebCore::SVGImage::draw):
2387         (WebCore::SVGImage::dataChanged):
2388         * svg/graphics/SVGImage.h:
2389
2390             The member variable 'm_intrinsicSize' has been added to track the image's intrinsic
2391             size. This term can be found in: http://www.w3.org/TR/css3-images/#default-sizing
2392
2393         * svg/graphics/SVGImageCache.cpp:
2394         (WebCore::SVGImageCache::imageSizeForRenderer):
2395         (WebCore::SVGImageCache::imageForRenderer):
2396
2397             In both of these functions, image has been renamed to imageForContainer here to clarify
2398             that the cached container size is being returned, not the image's intrinsic size.
2399
2400 2013-03-19  Joshua Bell  <jsbell@chromium.org>
2401
2402         IndexedDB: Use integer plumbing for deleteDatabase onVersionChange calls
2403         https://bugs.webkit.org/show_bug.cgi?id=112715
2404
2405         Reviewed by Tony Chang.
2406
2407         When deleteDatabase on the back-end needs to send the front-end an
2408         onVersionChange notification it does so using the string overload. That's
2409         the only remaining use of that overload and we'd like to delete it. Switch
2410         to using the integer overload, with an already defined special value.
2411         This will unblock http://wkbug.com/112712 to delete the dead code.
2412
2413         No new tests - no functional change.
2414
2415         * Modules/indexeddb/IDBDatabase.cpp:
2416         (WebCore::IDBDatabase::onVersionChange): Map NoIntVersion to null.
2417         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
2418         (WebCore::IDBDatabaseBackendImpl::deleteDatabase): Call integer overload.
2419
2420 2013-03-19  Terry Anderson  <tdanderson@chromium.org>
2421
2422         Hover effects from a GestureTapDown are dismissed by a GestureTap on the hover element
2423         https://bugs.webkit.org/show_bug.cgi?id=103283
2424
2425         Reviewed by Antonio Gomes.
2426
2427         On a GestureTap event over an element that was made visible as a hover effect, the
2428         GestureTap should be applied to that element and the hover effects should not be dismissed. 
2429         A GestureTap or a mouse move to a location outside of the element should still dismiss the
2430         hover effects.
2431
2432         Tests: fast/events/touch/gesture/gesture-tap-hover-clear.html
2433                fast/events/touch/gesture/gesture-tap-on-hover-element.html
2434
2435         * page/EventHandler.cpp:
2436         (WebCore::EventHandler::handleGestureEvent):
2437
2438 2013-03-19  Alexei Filippov  <alph@chromium.org>
2439
2440         Web Inspector: Fix menu items capitalization.
2441         https://bugs.webkit.org/show_bug.cgi?id=112553
2442
2443         The context menu items should be correctly capitalized.
2444
2445         Reviewed by Pavel Feldman.
2446
2447         * English.lproj/localizedStrings.js:
2448         * inspector/front-end/BreakpointsSidebarPane.js:
2449         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._emptyElementContextMenu):
2450         (WebInspector.XHRBreakpointsSidebarPane.prototype._emptyElementContextMenu):
2451         (WebInspector.XHRBreakpointsSidebarPane.prototype._contextMenu):
2452         * inspector/front-end/CallStackSidebarPane.js:
2453         (WebInspector.CallStackSidebarPane.Placard.prototype._placardContextMenu):
2454         * inspector/front-end/ConsoleView.js:
2455         (WebInspector.ConsoleView.prototype._handleContextMenuEvent.get var):
2456         (WebInspector.ConsoleView.prototype._handleContextMenuEvent.set get contextMenu):
2457         * inspector/front-end/DOMBreakpointsSidebarPane.js:
2458         (WebInspector.DOMBreakpointsSidebarPane.prototype._contextMenu):
2459         * inspector/front-end/DataGrid.js:
2460         (WebInspector.DataGrid.prototype._contextMenuInDataTable):
2461         * inspector/front-end/ElementsPanel.js:
2462         (WebInspector.ElementsPanel.prototype._contextMenuEventFired.set get var):
2463         (WebInspector.ElementsPanel.prototype.appendApplicableItems):
2464         * inspector/front-end/ElementsTreeOutline.js:
2465         (WebInspector.ElementsTreeOutline.prototype._contextMenuEventFired):
2466         (WebInspector.ElementsTreeElement.prototype._populateTagContextMenu):
2467         * inspector/front-end/HeapSnapshotDataGrids.js:
2468         (WebInspector.HeapSnapshotSortableDataGrid.prototype.populateContextMenu):
2469         * inspector/front-end/NetworkPanel.js:
2470         (WebInspector.NetworkPanel.prototype.appendApplicableItems):
2471         * inspector/front-end/ProfilesPanel.js:
2472         (WebInspector.ProfilesPanel.prototype._handleContextMenuEvent):
2473         (WebInspector.ProfilesPanel.prototype.appendApplicableItems):
2474         (WebInspector.ProfileSidebarTreeElement.prototype.handleContextMenuEvent):
2475         * inspector/front-end/ResourcesPanel.js:
2476         (WebInspector.FileSystemListTreeElement.prototype._handleContextMenuEvent):
2477         * inspector/front-end/ScriptsPanel.js:
2478         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeMappingItems):
2479         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeItems):
2480         (WebInspector.ScriptsPanel.prototype._appendFunctionItems):
2481         * inspector/front-end/TabbedPane.js:
2482         (WebInspector.TabbedPaneTab.prototype._tabContextMenu):
2483         * inspector/front-end/TimelinePanel.js:
2484         (WebInspector.TimelinePanel.prototype._contextMenu):
2485         * inspector/front-end/WatchExpressionsSidebarPane.js:
2486         (WebInspector.WatchExpressionsSection.prototype._emptyElementContextMenu):
2487         (WebInspector.WatchExpressionTreeElement.prototype.populateContextMenu):
2488
2489 2013-03-19  Alec Flett  <alecflett@chromium.org>
2490
2491         Inspector: IndexedDB clear button and menu item
2492         https://bugs.webkit.org/show_bug.cgi?id=112066
2493
2494         Reviewed by Vsevolod Vlasov.
2495
2496         Adds a button that can clear the contents of an objectStore from
2497         the IDBDataView, and a context menu from the ResourcesPanel that
2498         can do the same.
2499
2500         This also disables the Refresh button from the IDBDataView, so there
2501         is at least some visual feedback that the refresh button is working.
2502
2503         Tests: http/tests/inspector/indexeddb/database-data.html
2504
2505         * inspector/Inspector.json: New API clearObjectStore.
2506         * inspector/InspectorIndexedDBAgent.cpp: Implementation of clearObjectStore
2507         (WebCore):
2508         (ClearObjectStoreListener): Calls the original closure after the objectStore is cleared.
2509         (ClearObjectStore): Initiates the clear operation after the DB opens.
2510         * inspector/front-end/IndexedDBModel.js: Exposes clearObjectStore to the Model API.
2511         (WebInspector.IDBDataView): Add clear button and enable/disable clear and refresh buttons appropriately.
2512         * inspector/front-end/ResourcesPanel.js: Add a menu item and refresh the displayed data after the clear.
2513         * inspector/front-end/inspector.css: Add a style to show the right button for clear.
2514
2515 2013-03-19  Nate Chapin  <japhet@chromium.org>
2516
2517         Merge MainResourceLoader::responseReceived into DocumentLoader
2518         https://bugs.webkit.org/show_bug.cgi?id=112593
2519
2520         Part of the ongoing effort to merge MainResourceLoader entirely
2521         into DocumentLoader.
2522
2523         Reviewed by Adam Barth.
2524
2525         No new tests, refactor only.
2526
2527         * loader/DocumentLoader.cpp:
2528         (WebCore::DocumentLoader::DocumentLoader):
2529         (WebCore::DocumentLoader::stopLoading):
2530         (WebCore::DocumentLoader::finishedLoading): The only thing left in
2531             MainResourceLoader related to this function was a RefPtr which indirectly
2532             protected DocumentLoader. Move the RefPtr here and protect DocumentLoader directly.
2533         (WebCore::DocumentLoader::responseReceived): Moved from MainResourceLoader.
2534         (WebCore::DocumentLoader::callContinueAfterContentPolicy): Moved from MainResourceLoader.
2535         (WebCore::DocumentLoader::continueAfterContentPolicy): Moved from MainResourceLoader.
2536         (WebCore::DocumentLoader::interruptedForPolicyChangeError): Moved from MainResourceLoader.
2537         (WebCore::DocumentLoader::stopLoadingForPolicyChange): Moved from MainResourceLoader.
2538         (WebCore::DocumentLoader::receivedData):
2539         (WebCore::DocumentLoader::cancelMainResourceLoad):
2540         * loader/DocumentLoader.h:
2541         (WebCore::DocumentLoader::isLoadingMultipartContent): Store multipart bit here.
2542         * loader/MainResourceLoader.cpp:
2543         (WebCore::MainResourceLoader::MainResourceLoader):
2544         (WebCore::MainResourceLoader::cancel):
2545         (WebCore::MainResourceLoader::responseReceived):
2546         (WebCore::MainResourceLoader::notifyFinished):
2547         * loader/MainResourceLoader.h:
2548
2549 2013-03-19  Tony Chang  <tony@chromium.org>
2550
2551         Cleanup defaultUnifiedTextCheckerEnabled type
2552         https://bugs.webkit.org/show_bug.cgi?id=112640
2553
2554         Reviewed by Adam Barth.
2555
2556         It's a bool setting. I accidentally declared the default value as a double
2557         in r139202.
2558
2559         No new tests, this is a refactor/code cleanup.
2560
2561         * page/Settings.cpp:
2562         (WebCore): Switch from double to a bool.
2563
2564 2013-03-19  Alexei Filippov  <alph@chromium.org>
2565
2566         Web Inspector: Increase DataGrid default font size.
2567         https://bugs.webkit.org/show_bug.cgi?id=112692
2568
2569         Reviewed by Pavel Feldman.
2570
2571         The default font of 10px is too small. Most instances of DataGrid set
2572         font to 11px.
2573
2574         * inspector/front-end/dataGrid.css:
2575         (.data-grid table):
2576
2577 2013-03-19  Max Vujovic  <mvujovic@adobe.com>
2578
2579         Refactor conditions for setCompositingLayersNeedRebuild in RenderLayer::styleChanged
2580         https://bugs.webkit.org/show_bug.cgi?id=112606
2581
2582         Reviewed by Simon Fraser.
2583
2584         To fix bug 109098 [1], we will need to add more conditions for calling
2585         RenderLayerCompositor::setCompositingLayersNeedRebuild in RenderLayer::styleChanged.
2586         Adding more non-trivial conditions will make this block of code even harder to follow.
2587         This patch refactors the current conditions into functions:
2588             needsCompositingLayersRebuiltForClip
2589             needsCompositingLayersRebuiltForOverflow
2590
2591         In bug 109098 [1], I'm planning to add:
2592             needsCompositingLayersRebuiltForFilters
2593
2594         [1]: https://bugs.webkit.org/show_bug.cgi?id=109098
2595
2596         No new tests. Just refactoring.
2597
2598         * rendering/RenderLayer.cpp:
2599         (WebCore):
2600         (WebCore::RenderLayer::needsCompositingLayersRebuiltForClip):
2601         (WebCore::RenderLayer::needsCompositingLayersRebuiltForOverflow):
2602             This is a method and not a file static function because it needs to look at the
2603             RenderLayer's stackingContainer(), which is a private method.
2604         (WebCore::RenderLayer::styleChanged):
2605         * rendering/RenderLayer.h:
2606         (RenderLayer):
2607
2608 2013-03-19  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2609
2610         [Qt] Support kerning in fast path font rendering
2611         https://bugs.webkit.org/show_bug.cgi?id=106013
2612
2613         Reviewed by Jocelyn Turcotte.
2614
2615         To support kerning in the fast font path we need to implement SimpleFontData::applyTransforms.
2616
2617         This patch changes the types used by the fast path GlyphBuffer to match those used by Qt,
2618         and implements SimpleFontData::applyTransforms using QRawFont::advancesForGlyphIndexes.
2619
2620         * platform/graphics/GlyphBuffer.h:
2621         (GlyphBufferAdvance):
2622         (WebCore::GlyphBufferAdvance::GlyphBufferAdvance):
2623         (WebCore::GlyphBufferAdvance::setWidth):
2624         (WebCore::GlyphBufferAdvance::width):
2625         (WebCore::GlyphBufferAdvance::height):
2626         (WebCore::GlyphBuffer::add):
2627         * platform/graphics/SimpleFontData.h:
2628         (WebCore::SimpleFontData::applyTransforms):
2629         * platform/graphics/WidthIterator.h:
2630         (WebCore::WidthIterator::supportsTypesettingFeatures):
2631
2632 2013-03-19  Sergey Ryazanov  <serya@chromium.org>
2633
2634         Web Inspector: split Console into two entities, a web-facing bound object and page console.
2635         https://bugs.webkit.org/show_bug.cgi?id=111578
2636
2637         Reviewed by Vsevolod Vlasov.
2638
2639         Otherwise, a lot of logging in WebCore needs to go through the DOMWindow which is unnecessary.
2640
2641         * CMakeLists.txt:
2642         * GNUmakefile.list.am:
2643         * Target.pri:
2644         * WebCore.exp.in:
2645         * WebCore.gypi:
2646         * WebCore.order:
2647         * WebCore.vcproj/WebCore.vcproj:
2648         * WebCore.vcxproj/WebCore.vcxproj:
2649         * WebCore.vcxproj/WebCore.vcxproj.filters:
2650         * WebCore.xcodeproj/project.pbxproj:
2651         * bindings/js/JSCustomXPathNSResolver.cpp:
2652         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2653         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
2654         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
2655         * dom/Document.cpp:
2656         (WebCore::Document::addConsoleMessage):
2657         (WebCore::Document::addMessage):
2658         * inspector/PageDebuggerAgent.cpp:
2659         (WebCore::PageDebuggerAgent::muteConsole):
2660         (WebCore::PageDebuggerAgent::unmuteConsole):
2661         * inspector/PageRuntimeAgent.cpp:
2662         (WebCore::PageRuntimeAgent::muteConsole):
2663         (WebCore::PageRuntimeAgent::unmuteConsole):
2664         * page/Console.cpp:
2665         (WebCore::internalAddMessage):
2666         * page/Console.h:
2667         (WebCore):
2668         (Console):
2669         * page/DOMWindow.cpp:
2670         (WebCore::DOMWindow::pageConsole):
2671         (WebCore):
2672         (WebCore::DOMWindow::dispatchMessageEventWithOriginCheck):
2673         (WebCore::DOMWindow::printErrorMessage):
2674         * page/DOMWindow.h:
2675         (WebCore):
2676         (DOMWindow):
2677         * page/Page.cpp:
2678         (WebCore::Page::Page):
2679         * page/Page.h:
2680         (WebCore):
2681         (WebCore::Page::console):
2682         (Page):
2683         * page/PageConsole.cpp: Added.
2684         (WebCore::PageConsole::PageConsole):
2685         (WebCore):
2686         (WebCore::PageConsole::~PageConsole):
2687         (WebCore::PageConsole::printSourceURLAndLine):
2688         (WebCore::PageConsole::printMessageSourceAndLevelPrefix):
2689         (WebCore::PageConsole::addMessage):
2690         (WebCore::PageConsole::mute):
2691         (WebCore::PageConsole::unmute):
2692         (WebCore::PageConsole::shouldPrintExceptions):
2693         (WebCore::PageConsole::setShouldPrintExceptions):
2694         * page/PageConsole.h: Copied from Source/WebCore/page/Console.h.
2695         (WebCore):
2696         (PageConsole):
2697         (WebCore::PageConsole::create):
2698         (WebCore::PageConsole::page):
2699         * xml/XSLStyleSheetLibxslt.cpp:
2700         (WebCore::XSLStyleSheet::parseString):
2701         * xml/XSLTProcessorLibxslt.cpp:
2702         (WebCore::XSLTProcessor::parseErrorFunc):
2703         (WebCore::docLoaderFunc):
2704
2705 2013-03-19  Ilya Tikhonovsky  <loislo@chromium.org>
2706
2707         Web Inspector: move OverviewGrid and OverviewWindow into separate file.
2708         https://bugs.webkit.org/show_bug.cgi?id=112693
2709
2710         Reviewed by Yury Semikhatsky.
2711
2712         It is the third patch for the meta bug "Web Inspector: meta bug: extract OverviewGrid from TimelineOverviewPane"
2713         It just moves the OverviewGrid and the related classes into its own file.
2714
2715         * WebCore.gypi:
2716         * WebCore.vcproj/WebCore.vcproj:
2717         * WebCore.vcxproj/WebCore.vcxproj:
2718         * WebCore.vcxproj/WebCore.vcxproj.filters:
2719         * inspector/compile-front-end.py:
2720         * inspector/front-end/OverviewGrid.js: Added.
2721         (WebInspector.OverviewGrid):
2722         (WebInspector.OverviewGrid.prototype.itemsGraphsElement):
2723         (WebInspector.OverviewGrid.prototype.insertBeforeItemsGraphsElement):
2724         (WebInspector.OverviewGrid.prototype.clientWidth):
2725         (WebInspector.OverviewGrid.prototype.showItemsGraphsElement):
2726         (WebInspector.OverviewGrid.prototype.hideItemsGraphsElement):
2727         (WebInspector.OverviewGrid.prototype.updateDividers):
2728         (WebInspector.OverviewGrid.prototype.addEventDividers):
2729         (WebInspector.OverviewGrid.prototype.removeEventDividers):
2730         (WebInspector.OverviewGrid.prototype.setWindowPosition):
2731         (WebInspector.OverviewGrid.prototype.reset):
2732         (WebInspector.OverviewGrid.prototype.windowLeft):
2733         (WebInspector.OverviewGrid.prototype.windowRight):
2734         (WebInspector.OverviewGrid.prototype.setWindow):
2735         (WebInspector.OverviewGrid.prototype.addEventListener):
2736         (WebInspector.OverviewGrid.Window):
2737         (WebInspector.OverviewGrid.Window.prototype.reset):
2738         (WebInspector.OverviewGrid.Window.prototype._leftResizeElementDragging):
2739         (WebInspector.OverviewGrid.Window.prototype._rightResizeElementDragging):
2740         (WebInspector.OverviewGrid.Window.prototype._startWindowSelectorDragging):
2741         (WebInspector.OverviewGrid.Window.prototype._windowSelectorDragging):
2742         (WebInspector.OverviewGrid.Window.prototype._endWindowSelectorDragging):
2743         (WebInspector.OverviewGrid.Window.prototype._startWindowDragging):
2744         (WebInspector.OverviewGrid.Window.prototype._windowDragging):
2745         (WebInspector.OverviewGrid.Window.prototype._endWindowDragging):
2746         (WebInspector.OverviewGrid.Window.prototype._moveWindow):
2747         (WebInspector.OverviewGrid.Window.prototype._resizeWindowLeft):
2748         (WebInspector.OverviewGrid.Window.prototype._resizeWindowRight):
2749         (WebInspector.OverviewGrid.Window.prototype._resizeWindowMaximum):
2750         (WebInspector.OverviewGrid.Window.prototype._setWindow):
2751         (WebInspector.OverviewGrid.Window.prototype._setWindowPosition):
2752         (WebInspector.OverviewGrid.Window.prototype._onMouseWheel):
2753         (WebInspector.OverviewGrid.Window.prototype._zoom):
2754         (WebInspector.OverviewGrid.WindowSelector):
2755         (WebInspector.OverviewGrid.WindowSelector.prototype._createSelectorElement):
2756         (WebInspector.OverviewGrid.WindowSelector.prototype._close):
2757         (WebInspector.OverviewGrid.WindowSelector.prototype._updatePosition):
2758         * inspector/front-end/TimelineOverviewPane.js:
2759         * inspector/front-end/WebKit.qrc:
2760         * inspector/front-end/inspector.html:
2761
2762 2013-03-19  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2763
2764         [Qt] Monospace font does not render in proper sizes
2765         https://bugs.webkit.org/show_bug.cgi?id=93263
2766
2767         Reviewed by Jocelyn Turcotte.
2768
2769         Do not force fonts to use integer metrics. This was necessary when the fast font path
2770         only worked in integer but is now hindering accurate metrics. This is also required to
2771         make kerning in the fast-path look acceptable
2772
2773         Only enabled for Qt 5.1+ to avoid changing all the baselines for 5.0.
2774
2775         * platform/graphics/qt/FontPlatformDataQt.cpp:
2776         (WebCore::FontPlatformData::FontPlatformData):
2777
2778 2013-03-19  John J. Barton  <johnjbarton@chromium.org>
2779
2780         Web Inspector: Add iframe option to inspectedWindow.eval() extension API
2781         https://bugs.webkit.org/show_bug.cgi?id=106811
2782
2783         Reviewed by Vsevolod Vlasov.
2784
2785         Add a new case to the options processing in inspectedWindow.eval(), look
2786         for option.frameURL <string> and/or option.scriptExecutionContext: <string>, find the
2787         matching JS context in the runtimeModel, and call evaluate() in that
2788         context; or error if the context is not found. 
2789
2790         Test: http/tests/inspector/extensions-iframe-eval.html
2791
2792         * inspector/front-end/ExtensionServer.js:
2793         (WebInspector.ExtensionServer.prototype._onEvaluateOnInspectedPage):
2794         (WebInspector.ExtensionServer.prototype.):
2795         (WebInspector.ExtensionServer.prototype.evaluate):
2796         * inspector/front-end/ResourceTreeModel.js:
2797         (WebInspector.ResourceTreeModel.prototype.frames):
2798            Added read access to _frames
2799        * inspector/front-end/RuntimeModel.js:
2800         (WebInspector.RuntimeModel.prototype.contextListByFrame):
2801            Added access to a frame's contextList, removed contextByFrameAndSecurityOrigin()
2802         (WebInspector.FrameExecutionContextList.prototype.mainWorldContext):
2803            Added access to frame's mainWorldContext, rather than implicit first context.
2804            Now we can go from ResourceTreeModel -> frame -> contextList then either
2805            mainWorldContext() or contextBySecurityOrigin() to access contexts.
2806
2807         * inspector/front-end/ExtensionServer.js:
2808         (WebInspector.ExtensionServer.prototype.):
2809         (WebInspector.ExtensionServer.prototype._onEvaluateOnInspectedPage):
2810         (WebInspector.ExtensionServer.prototype.evaluate):
2811         * inspector/front-end/ResourceTreeModel.js:
2812         * inspector/front-end/RuntimeModel.js:
2813         (WebInspector.RuntimeModel.prototype.contextListByFrame):
2814         (WebInspector.FrameExecutionContextList.prototype.mainWorldContext):
2815
2816         * inspector/front-end/ExtensionServer.js:
2817         (WebInspector.ExtensionServer.prototype._onReload):
2818         (WebInspector.ExtensionServer.prototype.resolveURLToFrame.hasMatchingURL):
2819         (WebInspector.ExtensionServer.prototype.):
2820         (WebInspector.ExtensionServer.prototype.evaluate):
2821         * inspector/front-end/ResourceTreeModel.js:
2822         (WebInspector.ResourceTreeModel.prototype.frames):
2823         * inspector/front-end/RuntimeModel.js:
2824         (WebInspector.RuntimeModel.prototype.contextListByFrame):
2825         (WebInspector.FrameExecutionContextList.prototype.mainWorldContext):
2826
2827         * inspector/front-end/ExtensionServer.js:
2828         (WebInspector.ExtensionServer.prototype.resolveURLToFrame.hasMatchingURL):
2829         (WebInspector.ExtensionServer.prototype.):
2830         (WebInspector.ExtensionServer.prototype.evaluate):
2831         * inspector/front-end/ResourceTreeModel.js:
2832         (WebInspector.ResourceTreeModel.prototype.frames):
2833         * inspector/front-end/RuntimeModel.js:
2834         (WebInspector.RuntimeModel.prototype.contextListByFrame):
2835         (WebInspector.FrameExecutionContextList.prototype.mainWorldContext):
2836
2837 2013-03-19  Ilya Tikhonovsky  <loislo@chromium.org>
2838
2839         Web Inspector: rename TimelineOverviewWindow to OverviewGrid.Window and fix names for constants.
2840         https://bugs.webkit.org/show_bug.cgi?id=112685
2841
2842         Reviewed by Yury Semikhatsky.
2843
2844         It is the second patch which extracts OverviewGrid from TimelineOverviewPane.
2845         It renames internal components of OverviewGrid.
2846         WebInspector.TimelineOverviewWindow -> WebInspector.OverviewGrid.Window
2847         WebInspector.TimelineOverviewWindow.WindowSelector -> WebInspector.OverviewGrid.WindowSelector
2848
2849         and moves constants from WebInspector.TimelineOverviewWindow namespace to WebInspector.OverviewGrid namespace
2850
2851         * inspector/front-end/TimelineOverviewPane.js:
2852         (WebInspector.TimelineOverviewPane):
2853         (WebInspector.OverviewGrid):
2854         (WebInspector.OverviewGrid.Window):
2855         (WebInspector.OverviewGrid.Window.prototype._startWindowSelectorDragging):
2856         (WebInspector.OverviewGrid.Window.prototype._endWindowSelectorDragging):
2857         (WebInspector.OverviewGrid.Window.prototype._startWindowDragging):
2858         (WebInspector.OverviewGrid.Window.prototype._windowDragging):
2859         (WebInspector.OverviewGrid.Window.prototype._moveWindow):
2860         (WebInspector.OverviewGrid.Window.prototype._resizeWindowRight):
2861         (WebInspector.OverviewGrid.Window.prototype._setWindowPosition):
2862         (WebInspector.OverviewGrid.Window.prototype._onMouseWheel):
2863         (WebInspector.OverviewGrid.Window.prototype._zoom):
2864         (WebInspector.OverviewGrid.WindowSelector):
2865         (WebInspector.OverviewGrid.WindowSelector.prototype._createSelectorElement):
2866
2867 2013-03-19  Ilya Tikhonovsky  <loislo@chromium.org>
2868
2869         Web Inspector: move _timelineGrid && _timelineOverviewWindow from TimelineOverviewPane into a new class OverviewGrid.
2870         https://bugs.webkit.org/show_bug.cgi?id=112584
2871
2872         Reviewed by Pavel Feldman.
2873
2874         It is the first path in the set.
2875         The end goal is to extract OverviewGrid with window selectors
2876         into a separate class in separate file and reuse it in CPU FlameChart.
2877
2878         * inspector/front-end/TimelineOverviewPane.js:
2879         (WebInspector.TimelineOverviewPane):
2880         (WebInspector.OverviewGrid):
2881         (WebInspector.OverviewGrid.prototype.get grid):
2882         (WebInspector.OverviewGrid.prototype.get clientWidth):
2883         (WebInspector.OverviewGrid.prototype.showItemsGraphsElement):
2884         (WebInspector.OverviewGrid.prototype.hideItemsGraphsElement):
2885         (WebInspector.OverviewGrid.prototype.updateDividers):
2886         (WebInspector.OverviewGrid.prototype.addEventDividers):
2887         (WebInspector.OverviewGrid.prototype.removeEventDividers):
2888         (WebInspector.OverviewGrid.prototype.setWindowPosition):
2889         (WebInspector.OverviewGrid.prototype.reset):
2890         (WebInspector.OverviewGrid.prototype.get windowLeft):
2891         (WebInspector.OverviewGrid.prototype.get windowRight):
2892         (WebInspector.OverviewGrid.prototype.setWindow):
2893         (WebInspector.OverviewGrid.prototype.addEventListener):
2894         (WebInspector.TimelineOverviewPane.prototype.setMode):
2895         (WebInspector.TimelineOverviewPane.prototype._setFrameMode):
2896         (WebInspector.TimelineOverviewPane.prototype._update):
2897         (WebInspector.TimelineOverviewPane.prototype.sidebarResized):
2898         (WebInspector.TimelineOverviewPane.prototype.zoomToFrame):
2899         (WebInspector.TimelineOverviewPane.prototype._reset):
2900         (WebInspector.TimelineOverviewPane.prototype.windowLeft):
2901         (WebInspector.TimelineOverviewPane.prototype.windowRight):
2902         (WebInspector.TimelineOverviewPane.prototype._updateWindow):
2903
2904 2013-03-19  Vladislav Kaznacheev  <kaznacheev@chromium.org>
2905
2906         Web Inspector: Add Inspector.targetCrashed event to Inspector protocol.
2907         https://bugs.webkit.org/show_bug.cgi?id=112669
2908
2909         Added Inspector.targetCrashed event and handled it on the front end.
2910         Showing a modal dialog similar to the one displayed when the remote
2911         debugging target is disconnected.
2912
2913         Reviewed by Pavel Feldman.
2914
2915         * English.lproj/localizedStrings.js:
2916         * inspector/Inspector.json:
2917         * inspector/front-end/HelpScreen.js:
2918         (WebInspector.HelpScreenUntilReload):
2919         (WebInspector.HelpScreenUntilReload.prototype.willHide):
2920         * inspector/front-end/inspector.js:
2921         (WebInspector.targetCrashed):
2922
2923 2013-03-19  Mario Sanchez Prada  <mario.prada@samsung.com>
2924
2925         [GTK] Wrong guard USE(GLX) in RedirectedXCompositeWindow
2926         https://bugs.webkit.org/show_bug.cgi?id=112600
2927
2928         Reviewed by Martin Robinson.
2929
2930         Replace USE(GLX) condition with USE(OPENGL) && PLATFORM(X11).
2931
2932         * platform/gtk/RedirectedXCompositeWindow.cpp: Updated guard.
2933         * platform/gtk/RedirectedXCompositeWindow.h: Ditto.
2934
2935 2013-03-19  Mihnea Ovidenie  <mihnea@adobe.com>
2936
2937         [CSSRegions] Crash reflowing content in variable width regions
2938         https://bugs.webkit.org/show_bug.cgi?id=112515
2939
2940         Reviewed by David Hyatt.
2941
2942         When removing floats during relayout of a line in a paginated context,
2943         we have to make sure that the floats collection actually has elements before
2944         accessing the last float from the collection.
2945         This situation arises when a block had floats in a previous layout and after
2946         they were removed, m_floatingObjects is not destroyed, only emptied.
2947
2948         Test: fast/regions/crash-reflow-inline-content-in-variable-width-regions.html
2949
2950         * rendering/RenderBlock.cpp:
2951         (WebCore::RenderBlock::removeFloatingObjectsBelow):
2952         * rendering/RenderBlockLineLayout.cpp:
2953         (WebCore::RenderBlock::layoutRunsAndFloats):
2954         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
2955
2956 2013-03-18  Vsevolod Vlasov  <vsevik@chromium.org>
2957
2958         Web Inspector: Debugger scripts should visually differ from network/filesystem files in workspace.
2959         https://bugs.webkit.org/show_bug.cgi?id=112552
2960
2961         Reviewed by Pavel Feldman.
2962
2963         Extracted ContentProviderBasedProjectDelegate from SimpleProjectDelegate.
2964         Implemented DebuggerProjectDelegate for DefaultScriptMapping.
2965         Debugger scripts are now added to workspace with a name starting with [VM] and ending with scriptId.
2966         Added yellow background to debugger scripts editor.
2967
2968         * WebCore.gypi:
2969         * WebCore.vcproj/WebCore.vcproj:
2970         * inspector/compile-front-end.py:
2971         * inspector/front-end/ContentProviderBasedProjectDelegate.js: Added.
2972         * inspector/front-end/DefaultScriptMapping.js:
2973         (WebInspector.DefaultScriptMapping):
2974         (WebInspector.DefaultScriptMapping.prototype.addScript):
2975         (WebInspector.DefaultScriptMapping.prototype._debuggerReset):
2976         (WebInspector.DebuggerProjectDelegate):
2977         (WebInspector.DebuggerProjectDelegate.prototype.id):
2978         (WebInspector.DebuggerProjectDelegate.prototype.type):
2979         (WebInspector.DebuggerProjectDelegate.prototype.displayName):
2980         (WebInspector.DebuggerProjectDelegate.prototype.addScript):
2981         * inspector/front-end/JavaScriptSourceFrame.js:
2982         (WebInspector.JavaScriptSourceFrame):
2983         * inspector/front-end/ParsedURL.js:
2984         (WebInspector.ParsedURL.splitURL):
2985         * inspector/front-end/SimpleWorkspaceProvider.js:
2986         (WebInspector.SimpleProjectDelegate):
2987         (WebInspector.SimpleProjectDelegate.prototype.addFile):
2988         (WebInspector.SimpleProjectDelegate.prototype._ensureUniquePath):
2989         (WebInspector.SimpleWorkspaceProvider.prototype._innerAddFileForURL):
2990         * inspector/front-end/WebKit.qrc:
2991         * inspector/front-end/Workspace.js:
2992         (WebInspector.Workspace.prototype.uiSourceCodeForURL):
2993         * inspector/front-end/inspector.html:
2994         * inspector/front-end/javaScriptSourceFrame.css: Added.
2995         (.source-frame-debugger-script):
2996
2997 2013-03-19  Andrey Lushnikov  <lushnikov@chromium.org>
2998
2999         Web Inspector: [CodeMirror] add smart braces functionality
3000         https://bugs.webkit.org/show_bug.cgi?id=112138
3001
3002         Reviewed by Vsevolod Vlasov.
3003
3004         No new tests.
3005
3006         Add closebrackets add-on to codemirror which implements smart braces
3007         functionality and guard this setting with the "Text Editor smart
3008         braces" experiment.
3009
3010         * WebCore.gypi:
3011         * WebCore.vcproj/WebCore.vcproj:
3012         * WebCore.vcxproj/WebCore.vcxproj:
3013         * WebCore.vcxproj/WebCore.vcxproj.filters:
3014         * inspector/front-end/CodeMirrorTextEditor.js:
3015         * inspector/front-end/WebKit.qrc:
3016         * inspector/front-end/cm/closebrackets.js: Added.
3017         (.):
3018
3019 2013-03-19  Andrey Lushnikov  <lushnikov@chromium.org>
3020
3021         Web Inspector: Avoid forcing text editor resize
3022         https://bugs.webkit.org/show_bug.cgi?id=112581
3023
3024         Reviewed by Vsevolod Vlasov.
3025
3026         No new tests.
3027
3028         Avoid unnecessary text editor resizing by removing line decoration
3029         via removeDecoration method instead of DOM remove operation.
3030
3031         * inspector/front-end/SourceFrame.js:
3032         (WebInspector.SourceFrame.prototype.clearMessages):
3033         (WebInspector.SourceFrame.prototype._setTextEditorDecorations):
3034
3035 2013-03-19  Andrey Lushnikov  <lushnikov@chromium.org>
3036
3037         Web Inspector: [CodeMirror] fix cursor movements
3038         https://bugs.webkit.org/show_bug.cgi?id=112555
3039
3040         Reviewed by Vsevolod Vlasov.
3041
3042         No new tests.
3043
3044         - Update CodeMirror to ToT to include its improved cursor movement
3045         - Add a small keymap to force cursor stop on both line endings and line
3046         starts.
3047
3048         * inspector/front-end/CodeMirrorTextEditor.js:
3049         (WebInspector.CodeMirrorTextEditor):
3050         (WebInspector.CodeMirrorTextEditor.FixWordMovement):
3051         (WebInspector.CodeMirrorTextEditor.FixWordMovement.moveRight):
3052         * inspector/front-end/cm/codemirror.css:
3053         (.CodeMirror div.CodeMirror-cursor):
3054         (.CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor):
3055         (.CodeMirror):
3056         * inspector/front-end/cm/codemirror.js:
3057         (window.CodeMirror):
3058         (window.CodeMirror.):
3059
3060 2013-03-19  Adam Barth  <abarth@webkit.org>
3061
3062         [chromium] Regression(143825): select elements don't open when there is a marquee on the page
3063         https://bugs.webkit.org/show_bug.cgi?id=111278
3064
3065         Unreviewed.
3066
3067         This patch is a rollout of http://trac.webkit.org/changeset/143825. The
3068         original patch caused a regression in the Chromium port.
3069
3070         * rendering/RenderLayer.cpp:
3071         (WebCore::RenderLayer::scrollTo):
3072
3073 2013-03-19  Alexander Pavlov  <apavlov@chromium.org>
3074
3075         Web Inspector: [Styles] Matching @host rule children are not displayed
3076         https://bugs.webkit.org/show_bug.cgi?id=112664
3077
3078         Reviewed by Vsevolod Vlasov.
3079
3080         Process host rules' contents akin to media rules' when handling the CSS model and source data.
3081
3082         Test: platform/chromium/inspector/styles/host-rules.html
3083
3084         * inspector/InspectorStyleSheet.cpp:
3085         (flattenSourceData):
3086         (WebCore::asCSSRuleList):
3087
3088 2013-03-18  Alexander Pavlov  <apavlov@chromium.org>
3089
3090         Web Inspector: [Styles] The "inherit" property value should be suggested for all properties
3091         https://bugs.webkit.org/show_bug.cgi?id=112662
3092
3093         Reviewed by Vsevolod Vlasov.
3094
3095         * inspector/front-end/CSSMetadata.js:
3096         (WebInspector.CSSMetadata.keywordsForProperty):
3097
3098 2013-03-18  David Kilzer  <ddkilzer@apple.com>
3099
3100         BUILD FIX (r146088): ResourceRequest::cfURLRequest() is defined twice on iOS
3101         <http://webkit.org/b/112387>
3102
3103         * platform/network/mac/ResourceRequestMac.mm:
3104         (WebCore::ResourceRequest::cfURLRequest): Move method into
3105         !USE(CFNETWORK) section since it's also defined in
3106         cf/ResourceRequestCFNet.cpp on iOS.
3107
3108 2013-03-18  Alpha Lam  <hclam@chromium.org>
3109
3110         [chromium] More tracing in deferred image decoding
3111         https://bugs.webkit.org/show_bug.cgi?id=112648
3112
3113         Reviewed by James Robinson.
3114
3115         Adding more trace events for a couple things in deferred image decoding path:
3116         - Time span for each lock pixels of SkPixelRef.
3117         - Time spent on decoding, scaling and pruning. Also the stack trace for these events.
3118         - Memory usage and number of cached entries.
3119         - Number of decode & scale operations done per image.
3120
3121         No test as this just add tracing information and no behavior change.
3122
3123         * platform/graphics/chromium/ImageDecodingStore.cpp:
3124         (WebCore::ImageDecodingStore::prune):
3125         (WebCore::ImageDecodingStore::insertCacheInternal):
3126         (WebCore::ImageDecodingStore::removeFromCacheInternal):
3127         * platform/graphics/chromium/ImageFrameGenerator.cpp:
3128         (WebCore::ImageFrameGenerator::ImageFrameGenerator):
3129         (WebCore::ImageFrameGenerator::decodeAndScale):
3130         (WebCore::ImageFrameGenerator::tryToScale):
3131         (WebCore::ImageFrameGenerator::tryToResumeDecodeAndScale):
3132         (WebCore::ImageFrameGenerator::tryToDecodeAndScale):
3133         (WebCore::ImageFrameGenerator::decode):
3134         * platform/graphics/chromium/ImageFrameGenerator.h:
3135         (ImageFrameGenerator):
3136         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
3137         (WebCore::LazyDecodingPixelRef::onLockPixels):
3138         (WebCore::LazyDecodingPixelRef::onUnlockPixels):
3139         (WebCore::LazyDecodingPixelRef::PrepareToDecode):
3140
3141 2013-03-18  Kentaro Hara  <haraken@chromium.org>
3142
3143         Unreviewed. Rebaselined run-bindings-tests after r146161.
3144
3145         * bindings/scripts/test/JS/JSTestObj.cpp:
3146         (WebCore::setJSTestObjEnumAttr):
3147         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
3148         * bindings/scripts/test/V8/V8TestObj.cpp:
3149         (WebCore::ConfigureV8TestObjTemplate):
3150
3151 2013-03-18  Robert Flack  <flackr@chromium.org>
3152
3153         [chromium] Small pixel differences in scroll bars after r145844
3154         https://bugs.webkit.org/show_bug.cgi?id=112384
3155
3156         Reviewed by Kenneth Russell.
3157
3158         Tests: fast/forms/basic-textareas-quirks.html
3159                fast/forms/basic-textareas.html
3160                fast/overflow/overflow-x-y.html
3161                fast/parser/open-comment-in-textarea.html
3162                fast/replaced/width100percent-textarea.html
3163
3164         * platform/chromium/ScrollbarThemeChromium.cpp:
3165         (WebCore::ScrollbarThemeChromium::trackRect):
3166
3167 2013-03-18  Brent Fulgham  <bfulgham@webkit.org>
3168
3169         [WinCairo] Unreviewed build correction.
3170
3171         The "ImageDecoder.h" file was improperly tagged as a source file to
3172         build, causing a build failure on initial build attempts. Subsequent
3173         or incremental builds would work.
3174
3175         * WebCore.vcxproj/WebCore.vcxproj: Exclude CG-specific font files.
3176         Switch 'ImageDecoder.h' to proper source file type.
3177         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
3178
3179 2013-03-18  James Robinson  <jamesr@chromium.org>
3180
3181         [chromium] Remove unused type WebTransformationMatrix
3182         https://bugs.webkit.org/show_bug.cgi?id=112634
3183
3184         Reviewed by Adam Barth.
3185
3186         * WebCore.gypi:
3187         * platform/chromium/support/WebTransformationMatrix.cpp: Removed.
3188
3189 2013-03-18  Arnaud Renevier  <a.renevier@sisa.samsung.com>
3190
3191         Add IDL 'enum' support to CodeGeneratorJS.pm
3192         https://bugs.webkit.org/show_bug.cgi?id=112475
3193
3194         Reviewed by Kentaro Hara.
3195
3196         This adds support for enumerations in JS, adding validation checking
3197         to setters.
3198         It also does validation checking to methods, and a new method
3199         methodWithEnumArg in TestObj.idl
3200
3201         Test: bindings/scripts/test/TestObj.idl
3202
3203         * bindings/scripts/CodeGeneratorJS.pm:
3204         (GenerateImplementation):
3205         (GenerateParametersCheck):
3206         (NativeToJSValue):
3207         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
3208         (WebDOMTestObj::methodWithEnumArg):
3209         * bindings/scripts/test/CPP/WebDOMTestObj.h:
3210         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
3211         (webkit_dom_test_obj_method_with_enum_arg):
3212         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
3213         * bindings/scripts/test/JS/JSTestObj.cpp:
3214         (WebCore):
3215         (WebCore::jsTestObjEnumAttr):
3216         (WebCore::setJSTestObjEnumAttr):
3217         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
3218         * bindings/scripts/test/JS/JSTestObj.h:
3219         (WebCore):
3220         * bindings/scripts/test/ObjC/DOMTestObj.h:
3221         * bindings/scripts/test/ObjC/DOMTestObj.mm:
3222         (-[DOMTestObj methodWithEnumArg:]):
3223         * bindings/scripts/test/TestObj.idl:
3224         * bindings/scripts/test/V8/V8TestObj.cpp:
3225         (WebCore::TestObjV8Internal::methodWithEnumArgMethod):
3226         (TestObjV8Internal):
3227         (WebCore::TestObjV8Internal::methodWithEnumArgMethodCallback):
3228         (WebCore::ConfigureV8TestObjTemplate):
3229
3230 2013-03-18  Sam Weinig  <sam@webkit.org>
3231
3232         Need a bundle SPI to generate a snapshot of a specific DOM node (like [DOMNode renderedImage])
3233         <rdar://problem/13148631>
3234         https://bugs.webkit.org/show_bug.cgi?id=110034
3235
3236         Reviewed by Tim Horton.
3237
3238         * WebCore.exp.in:
3239         Add some necessary exports.
3240
3241 2013-03-18  Brent Fulgham  <bfulgham@webkit.org>
3242
3243         [WinCairo] Build WebCore under VS2010
3244         https://bugs.webkit.org/show_bug.cgi?id=112637
3245
3246         Reviewed by Tim Horton.
3247
3248         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj: Extend project
3249         with WinCairo-specific build targets.
3250         * WebCore.vcxproj/QTMovieWin/QTMovieWinCairoDebug.props: Added.
3251         * WebCore.vcxproj/QTMovieWin/QTMovieWinCairoRelease.props: Added.
3252         * WebCore.vcxproj/WebCore.vcxproj: Update to build WinCairo version
3253         of code.
3254         * WebCore.vcxproj/WebCoreCURL.props: Added.
3255         * WebCore.vcxproj/WebCoreCairo.props: Added.
3256         * WebCore.vcxproj/WebCoreDebugWinCairo.props: Added.
3257         * WebCore.vcxproj/WebCoreGenerated.vcxproj:
3258         * WebCore.vcxproj/WebCoreGeneratedDebugWinCairo.props: Added.
3259         * WebCore.vcxproj/WebCoreGeneratedReleaseWinCairo.props: Added.
3260         * WebCore.vcxproj/WebCoreGeneratedWinCairo.make: Added.
3261         * WebCore.vcxproj/WebCoreGeneratedWinCairoCommon.props: Added.
3262         * WebCore.vcxproj/WebCoreReleaseWinCairo.props: Added.
3263         * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
3264         * WebCorePrefix.h: Update header to not include Apple-specific
3265         headers during WinCairo build.
3266
3267 2013-03-18  Joshua Bell <jsbell@chromium.org>
3268
3269         IDB Cursor continue moves one item at a time
3270         https://bugs.webkit.org/show_bug.cgi?id=109972
3271
3272         Reviewed by Tony Chang.
3273
3274         IndexedDB: Use seek on the underlying levelDB iterator to implement the continue operation
3275         on a cursor, instead of advancing one item at a time. On a simple test in Chrome - open a
3276         key cursor on an index w/ 100 items, then do continue(50), rinse and repeat - this cuts the
3277         time 50% (850c/s to 1700c/s). (Original patch c/o Pankaj Kakkar <pankaj@google.com>)
3278
3279         Covered by existing storage/indexeddb cursor tests; just a performance optimization.
3280
3281         * Modules/indexeddb/IDBBackingStore.cpp:
3282         (WebCore::IDBBackingStore::Cursor::continueFunction): Special case first iteration w/ key
3283         to use leveldb seek (forward cursors only, since reverse seek isn't exposed).
3284         (WebCore::ObjectStoreKeyCursorImpl::encodeKey): Helper for encoding key to seek to.
3285         (WebCore::ObjectStoreCursorImpl::encodeKey): Ditto.
3286         (WebCore::IndexKeyCursorImpl::encodeKey): Ditto.
3287         (WebCore::IndexCursorImpl::encodeKey): Ditto.
3288         (WebCore::objectStoreCursorOptions): Store IDs for encodeKey() to use.
3289         (WebCore::indexCursorOptions): Ditto.
3290         * Modules/indexeddb/IDBBackingStore.h:
3291         (CursorOptions): Storage for IDs.
3292         (Cursor): Add encodeKey() to interface.
3293
3294 2013-03-18  Alexey Proskuryakov  <ap@apple.com>
3295
3296         MessagePortChannel::EventData should not be exposed
3297         https://bugs.webkit.org/show_bug.cgi?id=112635
3298
3299         Reviewed by Geoff Garen.
3300
3301         MessagePortChannel::EventData is an implementation detail that's only needed to
3302         store events in MessageQueue. Other existing code already gets away without it,
3303         just passing message and ports separately.
3304
3305         * dom/MessagePort.cpp:
3306         (WebCore::MessagePort::postMessage):
3307         (WebCore::MessagePort::dispatchMessages):
3308         * dom/MessagePortChannel.cpp:
3309         * dom/MessagePortChannel.h:
3310         * dom/default/PlatformMessagePortChannel.cpp:
3311         (WebCore::PlatformMessagePortChannel::EventData::create):
3312         (WebCore::PlatformMessagePortChannel::EventData::EventData):
3313         (WebCore::MessagePortChannel::postMessageToRemote):
3314         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
3315         * dom/default/PlatformMessagePortChannel.h:
3316         (WebCore::PlatformMessagePortChannel::EventData::message):
3317         (WebCore::PlatformMessagePortChannel::EventData::channels):
3318         (PlatformMessagePortChannel):
3319         (WebCore::PlatformMessagePortChannel::MessagePortQueue::tryGetMessage):
3320         (WebCore::PlatformMessagePortChannel::MessagePortQueue::appendAndCheckEmpty):
3321         * dom/default/chromium/PlatformMessagePortChannelChromium.cpp:
3322         (WebCore::MessagePortChannel::postMessageToRemote):
3323         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
3324         (WebCore::PlatformMessagePortChannel::postMessageToRemote):
3325         (WebCore::PlatformMessagePortChannel::tryGetMessageFromRemote):
3326         * dom/default/chromium/PlatformMessagePortChannelChromium.h:
3327
3328 2013-03-18  Tom Sepez  <tsepez@chromium.org>
3329
3330         [v8] Suppress binding integrity check of HTMLContentElement.
3331         https://bugs.webkit.org/show_bug.cgi?id=112613
3332
3333         Reviewed by Adam Barth.
3334
3335         Patch is correct so long as fast/dom/shadow/content-element-user-agent-shadow.html
3336         continues to pass.
3337
3338         * html/shadow/HTMLContentElement.idl:
3339
3340 2013-03-18  Dominic Mazzoni  <dmazzoni@google.com>
3341
3342         Support Windows HTMLSelectElement keystrokes on Chromium win
3343         https://bugs.webkit.org/show_bug.cgi?id=112460
3344
3345         Reviewed by Kent Tamura.
3346
3347         Compile in the windows-specific variant of
3348         HTMLSelectElement::platformHandleKeydownEvent
3349         on Chromium win, in addition to PLATFORM(WIN).
3350
3351         * WebCore.gypi:
3352             Add html/HTMLSelectElementWin.cpp.
3353         * html/HTMLSelectElement.cpp:
3354             Don't compile generic platformHandleKeydownEvent on
3355             Chromium win.
3356         * html/HTMLSelectElementWin.cpp:
3357             Only compile platformHandleKeydownEvent on Windows.
3358             Fix compile error in assertion.
3359         (WebCore):
3360
3361 2013-03-18  Mike West  <mkwst@chromium.org>
3362
3363         CSP 1.1: Schemeless source expressions match HTTPS resources on HTTP sites.
3364         https://bugs.webkit.org/show_bug.cgi?id=112573
3365
3366         Reviewed by Adam Barth.
3367
3368         Currently, the directive 'script-src example.com' would match only
3369         scripts served from 'http://example.com' when served on an HTTP site,
3370         and only scripts served from 'https://example.com' when served on an
3371         HTTPS site. This patch changes the matching behavior for ports that
3372         have enabled CSP_NEXT in order to encourage use of HTTPS resources by
3373         allow schemeless source expressions to match HTTPS origins when on
3374         HTTP sites.
3375
3376         Thread: http://lists.w3.org/Archives/Public/public-webappsec/2013Mar/0013.html
3377         Spec change: https://dvcs.w3.org/hg/content-security-policy/rev/a7dc8820946e
3378
3379         Test: http/tests/security/contentSecurityPolicy/source-list-parsing-10.html
3380
3381         * page/ContentSecurityPolicy.cpp:
3382         (WebCore::CSPSource::CSPSource):
3383             Pass the current policy into CSPSource so that we can check the
3384             protected resource's scheme inside schemeMatches, rather than
3385             overwriting the source expression's scheme before creating the
3386             CSPSource.
3387         (WebCore::CSPSource::schemeMatches):
3388             If CSP_NEXT is enabled, ensure that HTTPS resources match the
3389             HTTP scheme when loaded on HTTP pages with schemaless source
3390             expressions.
3391         (WebCore::CSPSource::portMatches):
3392             Check the port against the URL's scheme: if m_scheme isn't
3393             empty, this will match it. If m_scheme is empty, we can't
3394             do a strict match against it, nor can we do a strict match
3395             against the protected resource's port. Checking the URL's
3396             port against the default port for its scheme solves this
3397             problem elegantly.
3398         (WebCore::CSPSourceList::parse):
3399         (WebCore::CSPSourceList::addSourceSelf):
3400             Pass in the policy when creating a CSPSource object.
3401
3402 2013-03-15  Jer Noble  <jer.noble@apple.com>
3403
3404         Text track cues do not update sizes when entering or exiting full screen.
3405         https://bugs.webkit.org/show_bug.cgi?id=112472
3406
3407         Reviewed by Eric Carlson.
3408
3409         The style properties of the TextCueBoxes were not being updated after the size of the video bounds changed.
3410         Because getDisplayTree() will not do it when the cue itself has not changed, explicitly call videoSizeDidChange()
3411         from updateSizes().
3412
3413         * html/shadow/MediaControlElements.cpp:
3414         (WebCore::MediaControlTextTrackContainerElement::updateSizes): call videoSizeDidChange() on every active cue.
3415         * html/track/TextTrackCue.h:
3416         (WebCore::TextTrackCue::hasDisplayTree): returns whether or not the cue has created a display tree without side effects.
3417         (WebCore::TextTrackCue::videoSizeDidChange): Overridable empty method.
3418         * html/track/TextTrackCueGeneric.cpp:
3419         (WebCore::TextTrackCueGeneric::videoSizeDidChange): Update the CSS height attribute of the cue box using the new video size.
3420         * html/track/TextTrackCueGeneric.h:
3421
3422 2013-03-18  Mike West  <mkwst@chromium.org>
3423
3424         CSP 1.1: Add 'effective-directive' to violation reports.
3425         https://bugs.webkit.org/show_bug.cgi?id=112568
3426
3427         Reviewed by Adam Barth.
3428
3429         https://dvcs.w3.org/hg/content-security-policy/rev/bc2bb0e5072a
3430         introduced an 'effective-directive' field on CSP violation reports,
3431         which allows developers to distinguish between resource types when
3432         'default-src' is the violated directive.
3433
3434         This patch implements the new field behind the CSP_NEXT flag.
3435
3436         Test: http/tests/security/contentSecurityPolicy/1.1/report-uri-effective-directive.html
3437
3438         * page/ContentSecurityPolicy.cpp:
3439         (WebCore::CSPDirectiveList::checkSourceAndReportViolation):
3440         (WebCore::CSPDirectiveList::reportViolation):
3441             These methods now accept an additional parameter to pipe the
3442             effective directive from the initial callsite down into
3443             ContentSecurityPolicy::reportViolation.
3444         (WebCore::CSPDirectiveList::checkEvalAndReportViolation):
3445         (WebCore::CSPDirectiveList::checkNonceAndReportViolation):
3446         (WebCore::CSPDirectiveList::checkMediaTypeAndReportViolation):
3447         (WebCore::CSPDirectiveList::checkInlineAndReportViolation):
3448         (WebCore::CSPDirectiveList::allowScriptFromSource):
3449         (WebCore::CSPDirectiveList::allowObjectFromSource):
3450         (WebCore::CSPDirectiveList::allowChildFrameFromSource):
3451         (WebCore::CSPDirectiveList::allowImageFromSource):
3452         (WebCore::CSPDirectiveList::allowStyleFromSource):
3453         (WebCore::CSPDirectiveList::allowFontFromSource):
3454         (WebCore::CSPDirectiveList::allowMediaFromSource):
3455         (WebCore::CSPDirectiveList::allowConnectToSource):
3456         (WebCore::CSPDirectiveList::allowFormAction):
3457             These methods now pass the effective directive name down
3458             into checkSourceAndReportViolation or reportViolation.
3459         (WebCore::ContentSecurityPolicy::reportViolation):
3460         * page/ContentSecurityPolicy.h:
3461             This method now accepts a new parameter that carries
3462             the effective directive name. If CSP_NEXT is enabled,
3463             the field is added to the violation report before it's