94f29488ea08b14e186591dae4317f50ccdf988c
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-02-07  Benjamin Poulain  <bpoulain@apple.com>
2
3         Move pauseAnimation/pauseTransition from TestRunner to Internals
4         https://bugs.webkit.org/show_bug.cgi?id=109107
5
6         Reviewed by Anders Carlsson.
7
8         Tests: animations/animation-internals-api-multiple-keyframes.html
9                animations/animation-internals-api.html
10
11         * testing/Internals.cpp:
12         (WebCore::Internals::pauseAnimationAtTimeOnElement):
13         (WebCore):
14         (WebCore::Internals::pauseTransitionAtTimeOnElement):
15         * testing/Internals.h:
16         (Internals):
17         * testing/Internals.idl:
18
19 2013-02-07  Gavin Peters  <gavinp@chromium.org>
20
21         Unreviewed, rolling out r142155.
22         http://trac.webkit.org/changeset/142155
23         https://bugs.webkit.org/show_bug.cgi?id=82888
24
25         cr/win build broke.
26
27         * bindings/js/JSClipboardCustom.cpp:
28         (WebCore::JSClipboard::types):
29         * bindings/v8/custom/V8ClipboardCustom.cpp:
30         (WebCore::V8Clipboard::typesAccessorGetter):
31         * dom/Clipboard.h:
32         (Clipboard):
33         * platform/blackberry/ClipboardBlackBerry.cpp:
34         (WebCore::ClipboardBlackBerry::types):
35         * platform/blackberry/ClipboardBlackBerry.h:
36         (ClipboardBlackBerry):
37         * platform/chromium/ChromiumDataObject.cpp:
38         (WebCore::ChromiumDataObject::types):
39         * platform/chromium/ChromiumDataObject.h:
40         (ChromiumDataObject):
41         * platform/chromium/ClipboardChromium.cpp:
42         (WebCore::ClipboardChromium::types):
43         * platform/chromium/ClipboardChromium.h:
44         (ClipboardChromium):
45         * platform/efl/ClipboardEfl.cpp:
46         (WebCore::ClipboardEfl::types):
47         * platform/efl/ClipboardEfl.h:
48         (ClipboardEfl):
49         * platform/gtk/ClipboardGtk.cpp:
50         (WebCore::ClipboardGtk::types):
51         * platform/gtk/ClipboardGtk.h:
52         (ClipboardGtk):
53         * platform/mac/ClipboardMac.h:
54         (ClipboardMac):
55         * platform/mac/ClipboardMac.mm:
56         (WebCore::addHTMLClipboardTypesForCocoaType):
57         (WebCore::ClipboardMac::types):
58         * platform/qt/ClipboardQt.cpp:
59         (WebCore::ClipboardQt::types):
60         * platform/qt/ClipboardQt.h:
61         (ClipboardQt):
62         * platform/win/ClipboardWin.cpp:
63         (WebCore::addMimeTypesForFormat):
64         (WebCore::ClipboardWin::types):
65         * platform/win/ClipboardWin.h:
66         (ClipboardWin):
67
68 2013-02-07  Rik Cabanier  <cabanier@adobe.com>
69
70         Add support for parsing of -webkit-background-blend-mode
71         https://bugs.webkit.org/show_bug.cgi?id=108547
72
73         Reviewed by David Hyatt.
74
75         Added parsing and general CSS handling of -webkit-background-blend-mode per 
76         https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#background-blend-mode
77
78         Tests: css3/compositing/background-blend-mode-property-parsing.html
79                css3/compositing/background-blend-mode-property.html
80
81         * css/CSSComputedStyleDeclaration.cpp: Built value for getComputedStyle.
82         (WebCore):
83         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
84         * css/CSSParser.cpp: Parsed and stored value of -webkit-background-blend-mode.
85         (WebCore::CSSParser::parseValue):
86         (WebCore::CSSParser::parseFillProperty):
87         * css/CSSProperty.cpp: Listed -webkit-background-blend-mode as a non-inherited property.
88         (WebCore::CSSProperty::isInheritedProperty):
89         * css/CSSPropertyNames.in: Added -webkit-background-blend-mode as a CSS property.
90         * css/CSSToStyleMap.cpp: Mapped background blend mode from CSS value to enum.
91         (WebCore::CSSToStyleMap::mapFillBlendMode):
92         (WebCore):
93         * css/CSSToStyleMap.h: Added function declaration 'mapFillBlendMode'.
94         (CSSToStyleMap):
95         * css/StyleBuilder.cpp: Set up propery handler for -webkit-background-blend-mode.
96         (WebCore::StyleBuilder::StyleBuilder):
97         * rendering/style/FillLayer.cpp: Added code to store and retrieve the blend mode from a layer.
98         (WebCore::FillLayer::FillLayer):
99         (WebCore::FillLayer::operator=):
100         (WebCore::FillLayer::operator==):
101         (WebCore::FillLayer::fillUnsetProperties):
102         * rendering/style/FillLayer.h: Added function definitions to manage blend mode in a layer.
103         (WebCore::FillLayer::blendMode):
104         (WebCore::FillLayer::isBlendModeSet):
105         (WebCore::FillLayer::setBlendMode):
106         (WebCore::FillLayer::clearBlendMode):
107         (WebCore::FillLayer::initialFillBlendMode):
108         (FillLayer):
109
110 2013-02-07  Gavin Peters  <gavinp@chromium.org>
111
112         Unreviewed, rolling out r142142.
113         http://trac.webkit.org/changeset/142142
114         https://bugs.webkit.org/show_bug.cgi?id=109154
115
116         Mac expectations were not right. See http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=inspector-protocol%2Fnmi-webaudio-leak-test.html and http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=inspector-protocol%2Fnmi-webaudio.html .
117
118
119         * inspector/front-end/DefaultTextEditor.js:
120         (WebInspector.TextEditorMainPanel.prototype._registerShortcuts):
121
122 2013-02-07  Gavin Peters  <gavinp@chromium.org>
123
124         Unreviewed, rolling out r142081.
125         http://trac.webkit.org/changeset/142081
126         https://bugs.webkit.org/show_bug.cgi?id=109146
127
128         The patch caused a crash in inspector-protocol/nmi-webaudio*.html .
129
130         See http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=inspector-protocol%2Fnmi-webaudio-leak-test.html and http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=inspector-protocol%2Fnmi-webaudio.html .
131
132         * dom/WebCoreMemoryInstrumentation.cpp:
133         (WebCore):
134         * inspector/front-end/NativeMemorySnapshotView.js:
135         (WebInspector.MemoryBlockViewProperties._initialize):
136         * platform/PlatformMemoryInstrumentation.cpp:
137         (WebCore):
138
139 2013-02-07  Bear Travis  <betravis@adobe.com>
140
141         [CSS Exclusions] shape-inside does not properly handle padding or border
142         https://bugs.webkit.org/show_bug.cgi?id=102715
143
144         Reviewed by David Hyatt.
145
146         This patch positions the exclusion shape based on the value of the css box sizing
147         property. Geometry calculations happen in the shape coordinate space. For layout,
148         these coordinates are translated to the border-box coordinate system by adding
149         the appropriate offsets.
150
151         Test: fast/exclusions/shape-inside/shape-inside-box-sizing.html
152
153         * rendering/ExclusionShapeInfo.cpp:
154         (WebCore::::computedShape): Pass m_shapeLogicalWidth to the exclusion shape
155         geometry code.
156         * rendering/ExclusionShapeInfo.h:
157         (WebCore::ExclusionShapeInfo::setShapeSize): Adjust block layout dimensions to
158         shape dimensions when checking to see if the shape geometry must be recalculated.
159         (WebCore::ExclusionShapeInfo::shapeLogicalTop): Account for layout offsets.
160         (WebCore::ExclusionShapeInfo::shapeLogicalBottom): Ditto.
161         (WebCore::ExclusionShapeInfo::shapeLogicalLeft): Ditto.
162         (WebCore::ExclusionShapeInfo::shapeLogicalRight): Ditto.
163         (WebCore::ExclusionShapeInfo::logicalTopOffset): Return the offset from the logical
164         top of the border box to the logical top of the shape.
165         (WebCore::ExclusionShapeInfo::logicalLeftOffset): Return the offset from the logical
166         left of the border box to the logical left of the shape.
167         (ExclusionShapeInfo):
168         * rendering/ExclusionShapeInsideInfo.cpp:
169         (WebCore::ExclusionShapeInsideInfo::computeSegmentsForLine): Adjust line top to
170         be in shape coordinates.
171         (WebCore::ExclusionShapeInsideInfo::adjustLogicalLineTop): Ditto.
172         * rendering/ExclusionShapeInsideInfo.h:
173         (WebCore::ExclusionShapeInsideInfo::lineOverlapsShapeBounds): Use consistent
174         coordinate system (border box) to test for whether a line overlaps a shape.
175         (WebCore::ExclusionShapeInsideInfo::logicalLineTop): Include the logical offset
176         from the border box.
177         (WebCore::ExclusionShapeInsideInfo::logicalLineBottom): Ditto.
178
179 2013-02-07  Benjamin Poulain  <bpoulain@apple.com>
180
181         Upstream iOS isWebThread() and isUIThread()
182         https://bugs.webkit.org/show_bug.cgi?id=109130
183
184         Reviewed by Sam Weinig.
185
186         * bindings/objc/WebScriptObject.mm:
187         (+[WebScriptObject initialize]):
188         * platform/mac/SharedBufferMac.mm:
189         (+[WebCoreSharedBufferData initialize]):
190         #ifdef out the legacy initialization as it is not correct when
191         using a WebThread.
192
193 2013-02-07  Vivek Galatage  <vivek.vg@samsung.com>
194
195         Web Inspector: CPU pegged when inspecting LocalStorage that mutates.
196         https://bugs.webkit.org/show_bug.cgi?id=107937
197
198         Reviewed by Yury Semikhatsky.
199
200         The DOM storage agent will fire an event to the frontend based on the action
201         performed on the storage. Based on this action, the front-end will just add/update/remove
202         the entry in the view. This enhances the front-end responsiveness as the round trip
203         for fetching the storage entries has been eliminated.
204
205         Existing test: LayoutTests/inspector/storage-panel-dom-storage-update.html should verify the change
206
207         * inspector/Inspector.json:
208         * inspector/InspectorDOMStorageAgent.cpp:
209         (WebCore::InspectorDOMStorageAgent::didDispatchDOMStorageEvent):
210         * inspector/front-end/DOMStorage.js:
211         (WebInspector.DOMStorageModel.prototype._domStorageItemsCleared):
212         (WebInspector.DOMStorageModel.prototype._domStorageItemRemoved):
213         (WebInspector.DOMStorageModel.prototype._domStorageItemAdded):
214         (WebInspector.DOMStorageModel.prototype._domStorageItemUpdated):
215         (WebInspector.DOMStorageDispatcher.prototype.domStorageItemsCleared):
216         (WebInspector.DOMStorageDispatcher.prototype.domStorageItemRemoved):
217         (WebInspector.DOMStorageDispatcher.prototype.domStorageItemAdded):
218         (WebInspector.DOMStorageDispatcher.prototype.domStorageItemUpdated):
219         * inspector/front-end/DOMStorageItemsView.js:
220         (WebInspector.DOMStorageItemsView):
221         (WebInspector.DOMStorageItemsView.prototype.wasShown):
222         (WebInspector.DOMStorageItemsView.prototype._domStorageItemsCleared):
223         (WebInspector.DOMStorageItemsView.prototype._domStorageItemRemoved):
224         (WebInspector.DOMStorageItemsView.prototype._domStorageItemAdded):
225         (WebInspector.DOMStorageItemsView.prototype._domStorageItemUpdated):
226         (WebInspector.DOMStorageItemsView.prototype._update):
227         (WebInspector.DOMStorageItemsView.prototype._showDOMStorageEntries):
228         (WebInspector.DOMStorageItemsView.prototype._refreshButtonClicked):
229         (WebInspector.DOMStorageItemsView.prototype._editingCallback):
230         (WebInspector.DOMStorageItemsView.prototype._deleteCallback):
231         * inspector/front-end/ResourcesPanel.js:
232         (WebInspector.ResourcesPanel):
233         (WebInspector.ResourcesPanel.prototype._showDOMStorage.get if):
234         (WebInspector.ResourcesPanel.prototype._showDOMStorage):
235
236 2013-02-07  Dan Carney  <dcarney@google.com>
237
238         [v8] move persistent::new and ::dispose into same class
239         https://bugs.webkit.org/show_bug.cgi?id=109065
240
241         Reviewed by Adam Barth.
242
243         No new tests. No change in functionality.
244
245         * bindings/scripts/CodeGeneratorV8.pm:
246         (GenerateSingleConstructorCallback):
247         (GenerateEventConstructorCallback):
248         (GenerateNamedConstructorCallback):
249         (GenerateToV8Converters):
250         * bindings/scripts/test/V8/V8Float64Array.cpp:
251         (WebCore::V8Float64Array::createWrapper):
252         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
253         (WebCore::V8TestActiveDOMObject::createWrapper):
254         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
255         (WebCore::V8TestCustomNamedGetter::createWrapper):
256         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
257         (WebCore::V8TestEventConstructor::constructorCallback):
258         (WebCore::V8TestEventConstructor::createWrapper):
259         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
260         (WebCore::V8TestEventTarget::createWrapper):
261         * bindings/scripts/test/V8/V8TestException.cpp:
262         (WebCore::V8TestException::createWrapper):
263         * bindings/scripts/test/V8/V8TestInterface.cpp:
264         (WebCore::V8TestInterface::constructorCallback):
265         (WebCore::V8TestInterface::createWrapper):
266         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
267         (WebCore::V8TestMediaQueryListListener::createWrapper):
268         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
269         (WebCore::V8TestNamedConstructorConstructorCallback):
270         (WebCore::V8TestNamedConstructor::createWrapper):
271         * bindings/scripts/test/V8/V8TestNode.cpp:
272         (WebCore::V8TestNode::constructorCallback):
273         (WebCore::V8TestNode::createWrapper):
274         * bindings/scripts/test/V8/V8TestObj.cpp:
275         (WebCore::V8TestObj::constructorCallback):
276         (WebCore::V8TestObj::createWrapper):
277         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
278         (WebCore::V8TestOverloadedConstructors::constructor1Callback):
279         (WebCore::V8TestOverloadedConstructors::constructor2Callback):
280         (WebCore::V8TestOverloadedConstructors::constructor3Callback):
281         (WebCore::V8TestOverloadedConstructors::constructor4Callback):
282         (WebCore::V8TestOverloadedConstructors::createWrapper):
283         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
284         (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
285         (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
286         * bindings/v8/DOMDataStore.cpp:
287         * bindings/v8/DOMDataStore.h:
288         (WebCore::DOMDataStore::setWrapper):
289         (DOMDataStore):
290         (WebCore::DOMDataStore::set):
291         (WebCore::DOMDataStore::setWrapperInObject):
292         * bindings/v8/DOMWrapperMap.h:
293         (WebCore::DOMWrapperMap::get):
294         (WebCore::DOMWrapperMap::set):
295         (WebCore::DOMWrapperMap::removeAndDispose):
296         (WebCore::DOMWrapperMap::defaultWeakCallback):
297         * bindings/v8/ScriptWrappable.h:
298         (WebCore::ScriptWrappable::wrapper):
299         (WebCore::ScriptWrappable::setWrapper):
300         (WebCore::ScriptWrappable::reportMemoryUsage):
301         (ScriptWrappable):
302         (WebCore::ScriptWrappable::disposeWrapper):
303         (WebCore::ScriptWrappable::weakCallback):
304         * bindings/v8/V8DOMWindowShell.cpp:
305         (WebCore::V8DOMWindowShell::installDOMWindow):
306         * bindings/v8/V8DOMWrapper.h:
307         (V8DOMWrapper):
308         (WebCore::V8DOMWrapper::associateObjectWithWrapper):
309         * bindings/v8/V8NPObject.cpp:
310         (WebCore::weakNPObjectCallback):
311         (WebCore::createV8ObjectForNPObject):
312         (WebCore::forgetV8ObjectForNPObject):
313         * bindings/v8/WorkerScriptController.cpp:
314         (WebCore::WorkerScriptController::initializeContextIfNeeded):
315         * bindings/v8/WrapperTypeInfo.h:
316         (WebCore):
317         (WrapperConfiguration):
318         (WebCore::WrapperConfiguration::configureWrapper):
319         (WebCore::buildWrapperConfiguration):
320         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
321         (WebCore::V8ArrayBuffer::constructorCallbackCustom):
322         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
323         (WebCore::wrapArrayBufferView):
324         (WebCore::constructWebGLArray):
325         * bindings/v8/custom/V8AudioContextCustom.cpp:
326         (WebCore::V8AudioContext::constructorCallbackCustom):
327         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
328         (WebCore::V8DOMFormData::constructorCallbackCustom):
329         * bindings/v8/custom/V8DataViewCustom.cpp:
330         (WebCore::V8DataView::constructorCallbackCustom):
331         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
332         (WebCore::v8HTMLImageElementConstructorCallback):
333         * bindings/v8/custom/V8IntentCustom.cpp:
334         (WebCore::V8Intent::constructorCallbackCustom):
335         * bindings/v8/custom/V8MessageChannelCustom.cpp:
336         (WebCore::V8MessageChannel::constructorCallbackCustom):
337         * bindings/v8/custom/V8MutationObserverCustom.cpp:
338         (WebCore::V8MutationObserver::constructorCallbackCustom):
339         * bindings/v8/custom/V8WebKitPointCustom.cpp:
340         (WebCore::V8WebKitPoint::constructorCallbackCustom):
341         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
342         (WebCore::V8XMLHttpRequest::constructorCallbackCustom):
343
344 2013-02-07  Zan Dobersek  <zdobersek@igalia.com>
345
346         [Autotools] Remove uses of Automake FARSTREAM_(CFLAGS|LIBS) variables, USE_FARSTREAM conditional
347         https://bugs.webkit.org/show_bug.cgi?id=109198
348
349         Reviewed by Martin Robinson.
350
351         * GNUmakefile.am: Remove FARSTREAM_CFLAGS variable, it's not set to anything.
352
353 2013-02-07   Vineet Chaudhary  <rgf748@motorola.com>
354
355         Consider replacing return type of Clipboard::types() from ListHashSet<String> to Vector<String>
356         https://bugs.webkit.org/show_bug.cgi?id=82888
357
358         Reviewed by Kentaro Hara.
359
360         As part of removing custom bindings of types Array Clipboard::types() needs to return
361         Vector<String> than ListHashSet<String>
362
363         No new tests. Existing test should pass with this change as no behavoural changes.
364
365         * bindings/js/JSClipboardCustom.cpp: Replace data type from ListHashSet<> to Vector<>.
366         (WebCore::JSClipboard::types):
367         * bindings/v8/custom/V8ClipboardCustom.cpp: Ditto.
368         (WebCore::V8Clipboard::typesAccessorGetter): Ditto.
369         * dom/Clipboard.h: Ditto.
370         * platform/blackberry/ClipboardBlackBerry.cpp: Ditto.
371         (WebCore::ClipboardBlackBerry::types):
372         * platform/blackberry/ClipboardBlackBerry.h: Ditto.
373         * platform/chromium/ChromiumDataObject.cpp: Ditto.
374         (WebCore::ChromiumDataObject::types):
375         * platform/chromium/ChromiumDataObject.h: Ditto.
376         * platform/chromium/ClipboardChromium.cpp: Ditto.
377         (WebCore::ClipboardChromium::types):
378         * platform/chromium/ClipboardChromium.h: Ditto.
379         * platform/efl/ClipboardEfl.cpp: Ditto.
380         (WebCore::ClipboardEfl::types):
381         * platform/efl/ClipboardEfl.h: Ditto.
382         * platform/gtk/ClipboardGtk.cpp: Ditto.
383         (WebCore::ClipboardGtk::types):
384         * platform/gtk/ClipboardGtk.h: Ditto.
385         * platform/mac/ClipboardMac.h: Ditto.
386         * platform/mac/ClipboardMac.mm: Ditto.
387         (WebCore::addHTMLClipboardTypesForCocoaType):
388         (WebCore::ClipboardMac::types):
389         * platform/qt/ClipboardQt.cpp: Ditto.
390         (WebCore::ClipboardQt::types):
391         * platform/qt/ClipboardQt.h: Ditto.
392         * platform/win/ClipboardWin.cpp: Ditto.
393         (WebCore::addMimeTypesForFormat):
394         (WebCore::ClipboardWin::types):
395         * platform/win/ClipboardWin.h: Ditto.
396
397 2013-02-07  Kentaro Hara  <haraken@chromium.org>
398
399         [V8] StringCache::m_stringCache should be HashMap<StringImpl*, Persistent<String>>
400         https://bugs.webkit.org/show_bug.cgi?id=109123
401
402         Reviewed by Adam Barth.
403
404         Currently StringCache::m_stringCache is implemented as
405         HashMap<StringImpl*, v8::String*>. Given that v8::String*
406         can change when a GC is triggered, it is dangerous to store a raw pointer.
407         We should use HashMap<StringImpl*, v8::Persistent<v8::String>> instead.
408
409         This is a possible fix for an IndexedDB crash (https://bugs.webkit.org/show_bug.cgi?id=105363),
410         although I'm not sure if this patch fixes the crash. (I couldn't reproduce the crash.)
411
412         No tests. This change highly depends on GC behavior and thus it is
413         difficult to make a reliable test case.
414
415         * bindings/v8/V8ValueCache.cpp:
416         (WebCore::makeExternalString):
417         * bindings/v8/V8ValueCache.h:
418         (StringCache):
419
420 2013-01-27  Robert Hogan  <robert@webkit.org>
421
422         CSS 2.1 failure: floats-149 fails
423         https://bugs.webkit.org/show_bug.cgi?id=95772
424
425         Reviewed by David Hyatt.
426
427         Treat inlines that contain nothing but empty inlines as empty too so that they get a linebox.
428
429         Tests: fast/inline/inline-with-empty-inline-children.html
430                css2.1/20110323/floats-149.htm
431
432         * rendering/InlineIterator.h:
433         (WebCore::isEmptyInline):
434         * rendering/RenderBlockLineLayout.cpp:
435         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Now that empty inlines get a linebox any out-of-flow
436         objects inside an empty inline (on a line that is otherwise empty) won't get positioned while skipping 
437         through leading whitespace. 
438
439 2013-02-07  peavo@outlook.com  <peavo@outlook.com>
440
441         [WinCairo] Compile fix after r141981
442         https://bugs.webkit.org/show_bug.cgi?id=109184
443
444         Reviewed by Brent Fulgham.
445
446         * platform/network/curl/ResourceHandleCurl.cpp:
447         (WebCore::ResourceHandle::loadResourceSynchronously):
448
449 2013-02-07  Otto Derek Cheung  <otcheung@rim.com>
450
451         [BlackBerry] Cookie database isn't loaded into memory in some rare cases
452         https://bugs.webkit.org/show_bug.cgi?id=109202
453         PR 286189
454
455         Reviewed by Yong Li.
456         Internally Reviewed by Konrad Piascik.
457
458         If a get/setCookie call is made before the database is loaded, or if there's some
459         kind of error that causes the loading of the database to fail in the constructor
460         of CookieManager, the browser will get into a state where it seems like cookie is
461         permanenty disabled.
462
463         Instead of logging the errors and redispatching the setCookie, we should do a force sync
464         to load the cookie database before continuing.
465
466         Since the bug is so difficult to reproduce (I never did so myself), I did the follow test
467         to make sure the code path is correct:
468         1) Make sure original implementation is retained - open and loading done in the constructor
469         2) Removed opening and loading in constructor, the new calls in get/setcookies loaded the db just fine (although with
470         an initial lag because we are blocking WKT while performing SQLite options).
471         3) Removed loading in constructor, the new calls loaded the db just fine.
472
473         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.cpp:
474         (WebCore::CookieDatabaseBackingStore::openAndLoadDatabaseSynchronously):
475         (WebCore):
476         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
477         (CookieDatabaseBackingStore):
478         * platform/blackberry/CookieManager.cpp:
479         (WebCore::CookieManager::setCookies):
480         (WebCore::CookieManager::getCookie):
481         (WebCore::CookieManager::generateHtmlFragmentForCookies):
482         (WebCore::CookieManager::getRawCookies):
483
484 2013-02-07  Max Vujovic  <mvujovic@adobe.com>
485
486         [CSS Shaders] Add WebKitCSSFilterRule to DOMWindow.idl
487         https://bugs.webkit.org/show_bug.cgi?id=109082
488
489         Reviewed by Dean Jackson.
490
491         Add an entry for WebKitCSSFilterRuleConstructor in DOMWindow.idl.
492
493         Tests: css3/filters/custom-with-at-rule-syntax/parsing-at-rule-invalid.html
494                css3/filters/custom-with-at-rule-syntax/parsing-at-rule-valid.html
495
496         * page/DOMWindow.idl:
497
498 2013-02-07  Vsevolod Vlasov  <vsevik@chromium.org>
499
500         Web Inspector: Remove unused workspace field from NetworkUISourceCodeProvider
501         https://bugs.webkit.org/show_bug.cgi?id=109201
502
503         Reviewed by Pavel Feldman.
504
505         * inspector/front-end/NetworkUISourceCodeProvider.js:
506         (WebInspector.NetworkUISourceCodeProvider):
507         * inspector/front-end/inspector.js:
508
509 2013-02-07  Jessie Berlin  <jberlin@apple.com>
510
511         REGRESSION(r142003): Duplicate "Unknown" strings in LocalizedStrings.cpp not distinguished
512         by key
513         https://bugs.webkit.org/show_bug.cgi?id=109196
514
515         Reviewed by Eric Carlson.
516
517         * English.lproj/Localizable.strings:
518         Updated for the changes.
519         * platform/LocalizedStrings.cpp:
520         (WebCore::unknownFileSizeText):
521         Add a key.
522         (WebCore::textTrackNoLabelText):
523         Ditto.
524
525 2013-02-07  Vsevolod Vlasov  <vsevik@chromium.org>
526
527         Web Inspector: linkifyResourceAsNode produced anchor should not prefer resources to scripts panel.
528         https://bugs.webkit.org/show_bug.cgi?id=109197
529
530         Reviewed by Pavel Feldman.
531
532         Javascript syntax errors in console are now linkified so that they show sources panel by default.
533
534         * inspector/front-end/ResourceUtils.js:
535         (WebInspector.linkifyResourceAsNode):
536
537 2013-02-07  Eberhard Graether  <egraether@google.com>
538
539         Web Inspector: Add settings checkbox for composited layer borders
540         https://bugs.webkit.org/show_bug.cgi?id=109096
541
542         Reviewed by Pavel Feldman.
543
544         This change adds a checkbox to show composited layer borders to the WebInspector's
545         rendering settings and plumbs the setting to Chromium's WebLayerTreeView. The setting
546         is visible if InspectorClient::canShowDebugBorders() returns true.
547
548         No new tests.
549
550         * English.lproj/localizedStrings.js:
551         * inspector/Inspector.json:
552         * inspector/InspectorClient.h:
553         (WebCore::InspectorClient::canShowDebugBorders):
554         (WebCore::InspectorClient::setShowDebugBorders):
555         (InspectorClient):
556         * inspector/InspectorPageAgent.cpp:
557         (PageAgentState):
558         (WebCore::InspectorPageAgent::restore):
559         (WebCore::InspectorPageAgent::disable):
560         (WebCore::InspectorPageAgent::canShowDebugBorders):
561         (WebCore):
562         (WebCore::InspectorPageAgent::setShowDebugBorders):
563         * inspector/InspectorPageAgent.h:
564         * inspector/front-end/Settings.js:
565         * inspector/front-end/SettingsScreen.js:
566         (WebInspector.GenericSettingsTab):
567         (WebInspector.GenericSettingsTab.prototype.get _showDebugBordersChanged):
568         * inspector/front-end/inspector.js:
569         (WebInspector.doLoadedDone):
570
571 2013-02-07  Gavin Peters  <gavinp@chromium.org>
572
573         Unreviewed, rolling out r142141.
574         http://trac.webkit.org/changeset/142141
575         https://bugs.webkit.org/show_bug.cgi?id=108990
576
577         Reland r142112, will update Chromium expectations and create a
578         Chromium bug instead for the crash.
579
580         * CMakeLists.txt:
581         * Target.pri:
582         * WebCore.pri:
583         * page/scrolling/ScrollingCoordinator.cpp:
584         (WebCore::ScrollingCoordinator::create):
585         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp: Added.
586         (WebCore):
587         (WebCore::ScrollingCoordinatorCoordinatedGraphics::ScrollingCoordinatorCoordinatedGraphics):
588         (WebCore::ScrollingCoordinatorCoordinatedGraphics::setLayerIsFixedToContainerLayer):
589         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h: Added.
590         (WebCore):
591         (ScrollingCoordinatorCoordinatedGraphics):
592         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
593         (WebCore::CoordinatedGraphicsLayer::setFixedToViewport):
594         (WebCore):
595         (WebCore::CoordinatedGraphicsLayer::flushCompositingState):
596         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
597         (CoordinatedGraphicsLayerClient):
598         (CoordinatedGraphicsLayer):
599
600 2013-02-07  Andrey Lushnikov  <lushnikov@chromium.org>
601
602         Web Inspector: home button behaviour is wrong in DTE
603         https://bugs.webkit.org/show_bug.cgi?id=109154
604
605         Reviewed by Vsevolod Vlasov.
606
607         Handle home key shortcut explicitly in TextEditorMainPanel.
608
609         New test: inspector/editor/text-editor-home-button.html
610
611         * inspector/front-end/DefaultTextEditor.js:
612         (WebInspector.TextEditorMainPanel.prototype._registerShortcuts):
613         (WebInspector.TextEditorMainPanel.prototype._handleHomeKey):
614
615 2013-02-07  Gavin Peters  <gavinp@chromium.org>
616
617         Unreviewed, rolling out r142112.
618         http://trac.webkit.org/changeset/142112
619         https://bugs.webkit.org/show_bug.cgi?id=108990
620
621         The new test scrollingcoordinator/non-fast-scrollable-region-transformed- iframe.html crashes on Lion.
622
623         See http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=scrollingcoordinator%2Fnon-fast-scrollable-region-transformed-iframe.html
624
625         * CMakeLists.txt:
626         * Target.pri:
627         * WebCore.pri:
628         * page/scrolling/ScrollingCoordinator.cpp:
629         (WebCore::ScrollingCoordinator::create):
630         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp: Removed.
631         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h: Removed.
632         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
633         (WebCore::CoordinatedGraphicsLayer::flushCompositingState):
634         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
635         (CoordinatedGraphicsLayerClient):
636         (WebCore::CoordinatedGraphicsLayer::setFixedToViewport):
637
638 2013-02-07  Allan Sandfeld Jensen  <allan.jensen@digia.com>
639
640         Scrollbars misplaced with accelerated compositing for overflow scroll
641         https://bugs.webkit.org/show_bug.cgi?id=108625
642
643         Reviewed by Simon Fraser.
644
645         Scrollbars require their own layer if overflow scroll is composited,
646         otherwise the scrollbars would be rendered on the content layer and
647         not fixed to the viewport.
648
649         * rendering/RenderLayerBacking.cpp:
650         (WebCore::RenderLayerBacking::requiresHorizontalScrollbarLayer):
651         (WebCore::RenderLayerBacking::requiresVerticalScrollbarLayer):
652         (WebCore::RenderLayerBacking::requiresScrollCornerLayer):
653
654 2013-02-07  Mike West  <mkwst@chromium.org>
655
656         Don't ASSERT things about uninitialized variables.
657         https://bugs.webkit.org/show_bug.cgi?id=109187
658
659         Reviewed by Jochen Eisinger.
660
661         Rather than ASSERTing that an uninitialized ExceptionCode is non-zero
662         after some method executes, we should use the ASSERT_NO_EXCEPTION macro.
663
664         * editing/markup.cpp:
665         (WebCore::removeElementPreservingChildren):
666
667 2013-02-07  Andrey Lushnikov  <lushnikov@chromium.org>
668
669         Web Inspector: [Regression] breakpoint condition not editable
670         https://bugs.webkit.org/show_bug.cgi?id=109183
671
672         Reviewed by Vsevolod Vlasov.
673
674         Improve TextEditorMainPanel.selection() method to return null if the
675         selection is set inside of decoration element.
676
677         No new tests.
678
679         * inspector/front-end/DOMExtension.js:
680         (Node.prototype.enclosingNodeOrSelfWithClass): Improve to add iteration boundary.
681         * inspector/front-end/DefaultTextEditor.js:
682         (WebInspector.TextEditorMainPanel.prototype.selection):
683
684 2013-02-07  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
685
686         [WK2][EFL][QT]REGRESSION(r142045): Scrolling is broken
687         https://bugs.webkit.org/show_bug.cgi?id=109185
688
689         Reviewed by Kenneth Rohde Christiansen.
690
691         This patch is disabling paints clipping logic added at r142045 for the case 
692         when the view should render the entire contents (case of using tiled backing store).
693
694         No new tests, covered by plenty of existing manual tests that allow scrolling
695         (for example fixed-position.html).
696
697         * platform/ScrollView.cpp:
698         (WebCore::ScrollView::paint):
699
700 2013-02-07  Vladislav Kaznacheev  <kaznacheev@chromium.org>
701
702         Web Inspector: Show elements and sources sidebar panes in a tabbed pane when they are below the main pane
703         https://bugs.webkit.org/show_bug.cgi?id=107552
704
705         Reviewed by Pavel Feldman.
706
707         Removed the aspect ratio detection logic and implemented explicit user action "Split Horizontally" available
708         in Elements and Sources panels. When split horizontally the sidebar panes are organized into a tabbed pane.
709         This user action is behind an experimental flag.
710
711         No new tests.
712
713         * inspector/front-end/ContextMenu.js:
714         (WebInspector.ContextMenu.prototype.show):
715         * inspector/front-end/DOMBreakpointsSidebarPane.js:
716         (WebInspector.DOMBreakpointsSidebarPane.prototype.createProxy):
717         (WebInspector.DOMBreakpointsSidebarPane.prototype.onContentReady):
718         (WebInspector.DOMBreakpointsSidebarPane.Proxy):
719         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype.expanded):
720         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype.expand):
721         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype.collapse):
722         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype.onContentReady):
723         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype.wasShown):
724         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype._reattachBody):
725         * inspector/front-end/ElementsPanel.js:
726         (WebInspector.ElementsPanel):
727         (WebInspector.ElementsPanel.prototype._populateContextMenu):
728         * inspector/front-end/ScriptsPanel.js:
729         (WebInspector.ScriptsPanel.prototype._clearInterface):
730         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeItems):
731         (WebInspector.ScriptsPanel.prototype._contextMenuEventFired):
732         * inspector/front-end/Settings.js:
733         (WebInspector.ExperimentsSettings):
734         * inspector/front-end/SidebarPane.js:
735         (WebInspector.SidebarPane):
736         (WebInspector.SidebarPane.prototype.prepareContent):
737         (WebInspector.SidebarPane.prototype.expanded):
738         (WebInspector.SidebarPane.prototype.expand):
739         (WebInspector.SidebarPane.prototype.collapse):
740         (WebInspector.SidebarPane.prototype.onContentReady):
741         (WebInspector.SidebarPane.prototype._setExpandCallback):
742         (WebInspector.SidebarPaneStack.prototype.addPane):
743         (WebInspector.SidebarPaneStack.prototype.activePaneId):
744         (WebInspector.SidebarPaneStack.prototype.setActivePaneId):
745         (WebInspector.SidebarPaneStack.prototype._setExpanded):
746         (WebInspector.SidebarPaneStack.prototype._onPaneExpanded):
747         (WebInspector.SidebarPaneStack.prototype._collapsePane):
748         (WebInspector.SidebarTabbedPane):
749         (WebInspector.SidebarTabbedPane.prototype.addPane):
750         (WebInspector.SidebarTabbedPane.prototype.activePaneId):
751         (WebInspector.SidebarTabbedPane.prototype.setActivePaneId):
752         (WebInspector.SidebarPaneGroup):
753         (WebInspector.SidebarPaneGroup.prototype.setStacked):
754         (WebInspector.SidebarPaneGroup.prototype.addPane):
755         (WebInspector.SidebarPaneGroup.prototype.attachToPanel):
756         (WebInspector.SidebarPaneGroup.prototype.populateContextMenu.toggleSplitDirection):
757         (WebInspector.SidebarPaneGroup.prototype.get _contextMenuEventFired):
758         (WebInspector.SidebarPaneGroup.prototype._onSplitDirectionSettingChanged):
759         * inspector/front-end/SidebarView.js:
760         (WebInspector.SidebarView):
761         (WebInspector.SidebarView.prototype._updateSidebarElementStyle):
762         (WebInspector.SidebarView.prototype.setVertical):
763         (WebInspector.SidebarView.prototype.onResize):
764         * inspector/front-end/StylesSidebarPane.js:
765         (WebInspector.ComputedStyleSidebarPane.prototype.wasShown):
766         (WebInspector.ComputedStyleSidebarPane.prototype.prepareContent):
767         * inspector/front-end/inspector.css:
768         (.sidebar-pane .section .properties, .event-bar .event-properties):
769         (.pane-title):
770         (.sidebar-pane-toolbar):
771         (.sidebar-pane-toolbar > *):
772         (.sidebar-pane-toolbar > select):
773         (.sidebar-pane-toolbar > select:hover):
774         (.sidebar-pane-toolbar > select:active):
775         (.sidebar-pane-toolbar > select.select-settings):
776         (.sidebar-pane-toolbar > select.select-filter):
777         (.sidebar-pane-toolbar > select > option, .sidebar-pane-toolbar > select > hr):
778         (.sidebar-pane-toolbar > .pane-title-button):
779         (.sidebar-pane-toolbar > .pane-title-button:hover):
780         (.sidebar-pane-toolbar > .pane-title-button:active, .sidebar-pane-toolbar > .pane-title-button.toggled):
781         (.sidebar-pane-toolbar > .pane-title-button.add):
782         (.sidebar-pane-toolbar > .pane-title-button.element-state):
783         (.sidebar-pane-toolbar > .pane-title-button.refresh):
784         (.sidebar-pane):
785         (.sidebar-pane > .body):
786         (.sidebar-pane > .body .info):
787         (.sidebar-pane > .body .placard + .info):
788         (.sidebar-pane.visible > .body):
789         (.sidebar-pane > .body .breakpoint-condition):
790         (.sidebar-pane.visible:nth-last-of-type(1)):
791         (.sidebar-pane-subtitle):
792         (.sidebar-pane-subtitle input, .section .header input[type=checkbox]):
793         (.sidebar-pane .breakpoint-hit):
794
795 2013-02-07  Gavin Peters  <gavinp@chromium.org>
796
797         Unreviewed, rolling out r142111.
798         http://trac.webkit.org/changeset/142111
799         https://bugs.webkit.org/show_bug.cgi?id=108055
800
801         win7 bot didn't display Arabic, see http://test-results.appspot.com/dashboards/flakiness_dashboard.html#tests=platform%2Fchromium%2Ffast%2Fforms%2Fcalendar-picker%2Fcalendar-picker-appearance-required-ar.html
802
803         * Resources/pagepopups/calendarPicker.css:
804         (.today-clear-area .today-button):
805         * Resources/pagepopups/calendarPicker.js:
806         (CalendarPicker.prototype.fixWindowSize):
807
808 2013-02-07  Vsevolod Vlasov  <vsevik@chromium.org>
809
810         Web Inspector: [Regression] Map.size() returns negative values.
811         https://bugs.webkit.org/show_bug.cgi?id=109174
812
813         Reviewed by Yury Semikhatsky.
814
815         * inspector/front-end/utilities.js:
816
817 2013-02-07  Pavel Feldman  <pfeldman@chromium.org>
818
819         Web Inspector: break details are only rendered upon first debugger pause.
820         https://bugs.webkit.org/show_bug.cgi?id=109193
821
822         Reviewed by Vsevolod Vlasov.
823
824         * inspector/front-end/CallStackSidebarPane.js:
825         (WebInspector.CallStackSidebarPane.prototype.update):
826
827 2013-02-07  Gavin Peters  <gavinp@chromium.org>
828
829         Unreviewed, rolling out r142118.
830         http://trac.webkit.org/changeset/142118
831         https://bugs.webkit.org/show_bug.cgi?id=109044
832
833         Broke SVG! Oh noes!
834
835         * Modules/indexeddb/IDBCursor.cpp:
836         (WebCore::IDBCursor::direction):
837         * Modules/indexeddb/IDBObjectStore.cpp:
838         (WebCore):
839         * Modules/indexeddb/IDBTransaction.cpp:
840         (WebCore::IDBTransaction::mode):
841         * dom/ContainerNode.cpp:
842         (WebCore::ContainerNode::takeAllChildrenFrom):
843         * dom/Document.cpp:
844         (WebCore::Document::setTitle):
845         * dom/MessagePort.cpp:
846         (WebCore::MessagePort::dispatchMessages):
847         (WebCore::MessagePort::disentanglePorts):
848         * editing/DeleteButtonController.cpp:
849         (WebCore::enclosingDeletableElement):
850         (WebCore::DeleteButtonController::createDeletionUI):
851         (WebCore::DeleteButtonController::show):
852         * editing/EditorCommand.cpp:
853         (WebCore::unionDOMRanges):
854         * editing/ReplaceNodeWithSpanCommand.cpp:
855         (WebCore::swapInNodePreservingAttributesAndChildren):
856         * editing/ReplaceSelectionCommand.cpp:
857         (WebCore::ReplacementFragment::ReplacementFragment):
858         (WebCore::ReplacementFragment::removeNode):
859         (WebCore::ReplacementFragment::insertNodeBefore):
860         (WebCore::ReplacementFragment::insertFragmentForTestRendering):
861         (WebCore::ReplacementFragment::restoreAndRemoveTestRenderingNodesToFragment):
862         (WebCore::ReplaceSelectionCommand::insertAsListItems):
863         * editing/SplitTextNodeCommand.cpp:
864         (WebCore::SplitTextNodeCommand::doUnapply):
865         * editing/TextIterator.cpp:
866         (WebCore::CharacterIterator::range):
867         (WebCore::BackwardsCharacterIterator::range):
868         (WebCore::TextIterator::rangeFromLocationAndLength):
869         (WebCore::collapsedToBoundary):
870         * editing/htmlediting.cpp:
871         (WebCore::createTabSpanElement):
872         * editing/mac/EditorMac.mm:
873         (WebCore::Editor::fontForSelection):
874         (WebCore::Editor::fontAttributesForSelectionStart):
875         * editing/markup.cpp:
876         (WebCore::createMarkup):
877         (WebCore::trimFragment):
878         (WebCore::createFragmentFromMarkupWithContext):
879         (WebCore::fillContainerFromString):
880         (WebCore::createFragmentFromText):
881         (WebCore::createFragmentFromNodes):
882         * html/ColorInputType.cpp:
883         (WebCore::ColorInputType::createShadowSubtree):
884         * html/HTMLOptionsCollection.cpp:
885         (WebCore::HTMLOptionsCollection::add):
886         * html/HTMLTextAreaElement.cpp:
887         (WebCore::HTMLTextAreaElement::updatePlaceholderText):
888         * html/HTMLTextFormControlElement.cpp:
889         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition):
890         (WebCore::HTMLTextFormControlElement::setInnerTextValue):
891         * html/TextFieldInputType.cpp:
892         (WebCore::TextFieldInputType::updatePlaceholderText):
893         * html/ValidationMessage.cpp:
894         (WebCore::ValidationMessage::buildBubbleTree):
895         * html/shadow/MediaControlElementTypes.cpp:
896         (WebCore::MediaControlVolumeSliderElement::defaultEventHandler):
897         * inspector/InspectorPageAgent.cpp:
898         (WebCore::InspectorPageAgent::getCookies):
899         * inspector/InspectorStyleSheet.cpp:
900         (WebCore::InspectorStyleSheet::addRule):
901         * loader/appcache/ApplicationCacheHost.cpp:
902         (WebCore::ApplicationCacheHost::dispatchDOMEvent):
903         * page/DOMSelection.cpp:
904         (WebCore::DOMSelection::deleteFromDocument):
905         * page/DragController.cpp:
906         (WebCore::prepareClipboardForImageDrag):
907         * rendering/RenderTextControl.cpp:
908         (WebCore::RenderTextControl::visiblePositionForIndex):
909         * rendering/style/SVGRenderStyle.h:
910         (WebCore::SVGRenderStyle::initialBaselineShiftValue):
911         (WebCore::SVGRenderStyle::initialKerning):
912         (WebCore::SVGRenderStyle::initialStrokeDashOffset):
913         (WebCore::SVGRenderStyle::initialStrokeWidth):
914         * svg/SVGAnimatedLength.cpp:
915         (WebCore::sharedSVGLength):
916         (WebCore::SVGAnimatedLengthAnimator::addAnimatedTypes):
917         (WebCore::SVGAnimatedLengthAnimator::calculateAnimatedValue):
918         * svg/SVGAnimatedLengthList.cpp:
919         (WebCore::SVGAnimatedLengthListAnimator::addAnimatedTypes):
920         (WebCore::SVGAnimatedLengthListAnimator::calculateAnimatedValue):
921         * svg/SVGLength.cpp:
922         (WebCore::SVGLength::SVGLength):
923         * svg/SVGTextContentElement.cpp:
924         (WebCore::SVGTextContentElement::textLengthAnimated):
925         * svg/animation/SVGSMILElement.cpp:
926         (WebCore::constructQualifiedName):
927
928 2013-02-07  Kentaro Hara  <haraken@chromium.org>
929
930         Remove #if USE(V8) from IDBRequest.h
931         https://bugs.webkit.org/show_bug.cgi?id=109163
932
933         Reviewed by Andreas Kling.
934
935         The header included inside the #if USE(V8) macro is not used.
936         We can simply remove it.
937
938         No tests. No change in behavior.
939
940         * Modules/indexeddb/IDBRequest.h:
941
942 2013-02-07  Stephen Chenney  <schenney@chromium.org>
943
944         GraphicsContext::drawImageBuffer is inefficient
945         https://bugs.webkit.org/show_bug.cgi?id=104367
946
947         Reviewed by Dirk Schulze.
948
949         This patch converts all of the drawImage and drawImageBuffer
950         convenience methods (those that take parameters of various types) to
951         invoke the implementing method (that takes FloatRect src and dest)
952         directly, rather than through the next-most-convenient method as was
953         done previously. This will knock some layers off the stack compared
954         to the existing code, and may remove one or two constructor invocations.
955         This may be slightly more efficient, and also makes debugging simpler.
956
957         Also removes the unused drawImage method that takes and IntRect source
958         area and IntRect destination. It is not invoked anywhere in a standard
959         WebKit checkout.
960
961         No new tests. No change in functionality, just refactoring.
962
963         * platform/graphics/GraphicsContext.cpp:
964         (WebCore::GraphicsContext::drawImage): Modify all the convenience versions to call
965         the implementing version directly.
966         (WebCore::GraphicsContext::drawImageBuffer): Modify all the convenience versions
967         to call the implementing version directly.
968         * platform/graphics/GraphicsContext.h:
969         (GraphicsContext): Remove IntRect, IntRect version of drawImage.
970
971 2013-02-07  Kent Tamura  <tkent@chromium.org>
972
973         Conversion from localized numbers to HTML numbers should accept not only localized numbers but also HTML numbers
974         https://bugs.webkit.org/show_bug.cgi?id=109160
975
976         Reviewed by Kentaro Hara.
977
978         For example, A French user needs to specify a number to a number input
979         field. He might use a local decimal point, like 3,141592, or he might
980         use the standard decimal point like 3.141592. We had better accept both
981         of them.
982
983         We accepted both last year, but we changed the behavior so that we
984         accept only localized numbers because we had some cases where an input
985         string can be recognized as both of a localized number and the standard
986         number. e.g. 3.141 is 3141 in French locale and 3.141 in the
987         standard. Now we introduce a simple rule that we don't accept group
988         separator at all. So users won't confuse even if we accept both of
989         decimal points.
990
991         Test: fast/forms/number/number-l10n-input.html
992
993         * platform/text/PlatformLocale.cpp:
994         (WebCore::Locale::convertFromLocalizedNumber):
995         If the specified string contains invalid characters including group
996         separators, just return the specified string.
997
998 2013-02-07  Xiaobo Wang  <xbwang@torchmobile.com.cn>
999
1000         [BlackBerry] CHHW - Characters that are using 32 bits encoding get trunked to 16bits
1001         https://bugs.webkit.org/show_bug.cgi?id=109126
1002         PR 292540
1003
1004         Reviewed by Yong Li.
1005
1006         Change char code to 4 bytes.
1007         Need to convert UTF32 key char to UTF16 before constructing a WTF::String.
1008
1009         * platform/PlatformKeyboardEvent.h:
1010         (WebCore::PlatformKeyboardEvent::unmodifiedCharacter):
1011         (PlatformKeyboardEvent):
1012         * platform/blackberry/PlatformKeyboardEventBlackBerry.cpp:
1013         (WebCore::keyIdentifierForBlackBerryCharacter):
1014         (WebCore::windowsKeyCodeForBlackBerryCharacter):
1015         (WebCore::adjustCharacterFromOS):
1016         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1017
1018 2013-02-07  Mike West  <mkwst@chromium.org>
1019
1020         Replace ExceptionCode assertions with ASSERT_NO_EXCEPTION macro.
1021         https://bugs.webkit.org/show_bug.cgi?id=109044
1022
1023         Reviewed by Darin Adler.
1024
1025         The pattern:
1026
1027             ExceptionCode ec = 0;
1028             methodThatGeneratesException(ec);
1029             ASSERT(!ec);
1030
1031         is more clearly and succinctly written as:
1032
1033             methodThatGeneratesException(ASSERT_NO_EXCEPTION);
1034
1035         This patch replaces the occurances of the former that never touch 'ec'
1036         again with the latter. It does the same for 'ASSERT(ec == 0);' (and, as
1037         a drive-by, replaces 'ASSERT(ec == 0)' with 'ASSERT(!ec)' in places
1038         where it does indeed matter that 'ec' get set properly.
1039
1040         No change in behavior should result from this refactoring.
1041
1042         * Modules/indexeddb/IDBCursor.cpp:
1043         (WebCore::IDBCursor::direction):
1044         * Modules/indexeddb/IDBObjectStore.cpp:
1045         (WebCore):
1046         * Modules/indexeddb/IDBTransaction.cpp:
1047         (WebCore::IDBTransaction::mode):
1048         * dom/ContainerNode.cpp:
1049         (WebCore::ContainerNode::takeAllChildrenFrom):
1050         * dom/Document.cpp:
1051         (WebCore::Document::setTitle):
1052         * dom/MessagePort.cpp:
1053         (WebCore::MessagePort::dispatchMessages):
1054         (WebCore::MessagePort::disentanglePorts):
1055         * editing/DeleteButtonController.cpp:
1056         (WebCore::enclosingDeletableElement):
1057         (WebCore::DeleteButtonController::createDeletionUI):
1058             Replaced inline ASSERT with ASSERT_NO_EXCEPTION.
1059         (WebCore::DeleteButtonController::show):
1060             Replaced 'ASSERT(ec == 0)' with 'ASSERT(!ec)' to match the style guide.
1061         * editing/EditorCommand.cpp:
1062         (WebCore::unionDOMRanges):
1063         * editing/ReplaceNodeWithSpanCommand.cpp:
1064         (WebCore::swapInNodePreservingAttributesAndChildren):
1065         * editing/ReplaceSelectionCommand.cpp:
1066         (WebCore::ReplacementFragment::ReplacementFragment):
1067         (WebCore::ReplacementFragment::removeNode):
1068         (WebCore::ReplacementFragment::insertNodeBefore):
1069         (WebCore::ReplacementFragment::insertFragmentForTestRendering):
1070         (WebCore::ReplacementFragment::restoreAndRemoveTestRenderingNodesToFragment):
1071         (WebCore::ReplaceSelectionCommand::insertAsListItems):
1072         * editing/SplitTextNodeCommand.cpp:
1073         (WebCore::SplitTextNodeCommand::doUnapply):
1074         * editing/TextIterator.cpp:
1075         (WebCore::CharacterIterator::range):
1076         (WebCore::BackwardsCharacterIterator::range):
1077         (WebCore::TextIterator::rangeFromLocationAndLength):
1078         (WebCore::collapsedToBoundary):
1079         * editing/htmlediting.cpp:
1080         (WebCore::createTabSpanElement):
1081         * editing/mac/EditorMac.mm:
1082         (WebCore::Editor::fontForSelection):
1083         (WebCore::Editor::fontAttributesForSelectionStart):
1084         * editing/markup.cpp:
1085         (WebCore::createMarkup):
1086         (WebCore::trimFragment):
1087         (WebCore::createFragmentFromMarkupWithContext):
1088         (WebCore::fillContainerFromString):
1089         (WebCore::createFragmentFromText):
1090         (WebCore::createFragmentFromNodes):
1091         * html/ColorInputType.cpp:
1092         (WebCore::ColorInputType::createShadowSubtree):
1093             Replaced inline ASSERT with ASSERT_NO_EXCEPTION.
1094         * html/HTMLOptionsCollection.cpp:
1095         (WebCore::HTMLOptionsCollection::add):
1096             Replaced 'ASSERT(ec == 0)' with 'ASSERT(!ec)' to match the style guide.
1097         * html/HTMLTextAreaElement.cpp:
1098         (WebCore::HTMLTextAreaElement::updatePlaceholderText):
1099         * html/HTMLTextFormControlElement.cpp:
1100         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition):
1101         (WebCore::HTMLTextFormControlElement::setInnerTextValue):
1102         * html/TextFieldInputType.cpp:
1103         (WebCore::TextFieldInputType::updatePlaceholderText):
1104         * html/ValidationMessage.cpp:
1105         (WebCore::ValidationMessage::buildBubbleTree):
1106         * html/shadow/MediaControlElementTypes.cpp:
1107         (WebCore::MediaControlVolumeSliderElement::defaultEventHandler):
1108         * inspector/InspectorPageAgent.cpp:
1109         (WebCore::InspectorPageAgent::getCookies):
1110         * inspector/InspectorStyleSheet.cpp:
1111         (WebCore::InspectorStyleSheet::addRule):
1112         * loader/appcache/ApplicationCacheHost.cpp:
1113         (WebCore::ApplicationCacheHost::dispatchDOMEvent):
1114         * page/DOMSelection.cpp:
1115         (WebCore::DOMSelection::deleteFromDocument):
1116         * page/DragController.cpp:
1117         (WebCore::prepareClipboardForImageDrag):
1118         * rendering/RenderTextControl.cpp:
1119         (WebCore::RenderTextControl::visiblePositionForIndex):
1120         * rendering/style/SVGRenderStyle.h:
1121         (WebCore::SVGRenderStyle::initialBaselineShiftValue):
1122         (WebCore::SVGRenderStyle::initialKerning):
1123         (WebCore::SVGRenderStyle::initialStrokeDashOffset):
1124         (WebCore::SVGRenderStyle::initialStrokeWidth):
1125         * svg/SVGAnimatedLength.cpp:
1126         (WebCore::sharedSVGLength):
1127         (WebCore::SVGAnimatedLengthAnimator::addAnimatedTypes):
1128         (WebCore::SVGAnimatedLengthAnimator::calculateAnimatedValue):
1129         * svg/SVGAnimatedLengthList.cpp:
1130         (WebCore::SVGAnimatedLengthListAnimator::addAnimatedTypes):
1131         (WebCore::SVGAnimatedLengthListAnimator::calculateAnimatedValue):
1132         * svg/SVGLength.cpp:
1133         (WebCore::SVGLength::SVGLength):
1134         * svg/SVGTextContentElement.cpp:
1135         (WebCore::SVGTextContentElement::textLengthAnimated):
1136         * svg/animation/SVGSMILElement.cpp:
1137         (WebCore::constructQualifiedName):
1138             Replaced inline ASSERT with ASSERT_NO_EXCEPTION.
1139
1140 2013-02-07  Mary Wu  <mary.wu@torchmobile.com.cn>
1141
1142         [BlackBerry] Export mimeType in NetworkJob
1143         https://bugs.webkit.org/show_bug.cgi?id=109002
1144
1145         Reviewed by Yong Li.
1146
1147         NetworkJob will analysize resource mimetype and set it to resourceResponse,
1148         we will pass it on to be used by other Streams like download stream.
1149
1150         RIM bug# 284408, internally reviewed by Liam Quinn.
1151
1152         * platform/network/blackberry/NetworkJob.cpp:
1153         (WebCore::NetworkJob::mimeType):
1154         (WebCore):
1155         * platform/network/blackberry/NetworkJob.h:
1156         (NetworkJob):
1157
1158 2013-02-07  Peter Rybin  <prybin@chromium.org>
1159
1160         Web Inspector: support JavaScript variable mutation in protocol and V8 bindings
1161         https://bugs.webkit.org/show_bug.cgi?id=107829
1162
1163         A new command is added to protocol description and the call is passed through
1164         debugger agent through injected script and debugger script down to V8 mirror
1165         API. JSC bindings got a thorw exception stub.
1166
1167         Only declarative JavaScript scopes are supported (local, closure, catch). Other
1168         scopes (global, with) are not supported by V8 and not supported by protocol, because
1169         manual approach (direct property assigment) is available for them in form of evaluate
1170         commands and is more desirable because of a complex nature of operation (it can throw
1171         exception in several cases such as exception in setter function).
1172
1173         Reviewed by Pavel Feldman.
1174
1175         Test: inspector-protocol/debugger-setVariableValue.html
1176
1177         * bindings/js/JSInjectedScriptHostCustom.cpp:
1178         (WebCore::JSInjectedScriptHost::setFunctionVariableValue):
1179         (WebCore):
1180         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
1181         (WebCore::JSJavaScriptCallFrame::setVariableValue):
1182         (WebCore):
1183         * bindings/v8/DebuggerScript.js:
1184         (.):
1185         * bindings/v8/JavaScriptCallFrame.cpp:
1186         (WebCore::JavaScriptCallFrame::setVariableValue):
1187         (WebCore):
1188         * bindings/v8/JavaScriptCallFrame.h:
1189         (JavaScriptCallFrame):
1190         * bindings/v8/ScriptDebugServer.cpp:
1191         (WebCore::ScriptDebugServer::setFunctionVariableValue):
1192         (WebCore):
1193         * bindings/v8/ScriptDebugServer.h:
1194         (ScriptDebugServer):
1195         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1196         (WebCore::V8InjectedScriptHost::setFunctionVariableValueCallback):
1197         (WebCore):
1198         * bindings/v8/custom/V8JavaScriptCallFrameCustom.cpp:
1199         (WebCore::V8JavaScriptCallFrame::setVariableValueCallback):
1200         (WebCore):
1201         * inspector/InjectedScript.cpp:
1202         (WebCore::InjectedScript::setVariableValue):
1203         (WebCore):
1204         * inspector/InjectedScript.h:
1205         (InjectedScript):
1206         * inspector/InjectedScriptHost.idl:
1207         * inspector/InjectedScriptSource.js:
1208         (.):
1209         * inspector/Inspector.json:
1210         * inspector/InspectorDebuggerAgent.cpp:
1211         (WebCore::InspectorDebuggerAgent::getFunctionDetails):
1212         (WebCore::InspectorDebuggerAgent::setVariableValue):
1213         (WebCore):
1214         * inspector/InspectorDebuggerAgent.h:
1215         (InspectorDebuggerAgent):
1216         * inspector/JavaScriptCallFrame.idl:
1217
1218 2013-02-07  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1219
1220         [CoordinatedGraphics] Use ScrollingCoordinator to track fixed layers
1221         https://bugs.webkit.org/show_bug.cgi?id=108990
1222
1223         Reviewed by Noam Rosenthal.
1224
1225         WebCore keeps ScrollingCoordinator up-to-date about whether layers are fixed or not, so we
1226         don't need to traverse the tree every frame to get this information.
1227
1228         The function ScrollingCoordinator::setLayerIsFixedToContainerLayer() is called when
1229         RenderLayerBacking is updating its graphics layers.
1230
1231         The new code also works in new situations where the previous was broken: if a layer changed
1232         from being fixed to not fixed (but still kept as a layer for other reasons), the layer will
1233         be correctly updated. Previous implementation only had logic to mark layers as fixed, but
1234         not the other way round. A manual test was added to illustrate the solved problem.
1235
1236         Testing was done with the existing manual tests that make use of "position:fixed". Automatic
1237         tests are mostly not affected by this because usage of this information affects only the
1238         UseFixedLayout mode, not used by default in WebKitTestRunner. Work to improve this situation
1239         will be tracked in bug https://bugs.webkit.org/show_bug.cgi?id=109175.
1240
1241         * CMakeLists.txt:
1242         * Target.pri:
1243         * WebCore.pri:
1244         * page/scrolling/ScrollingCoordinator.cpp:
1245         (WebCore::ScrollingCoordinator::create): create specific version of ScrollingCoordinator.
1246         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp: Added.
1247         (WebCore):
1248         (WebCore::ScrollingCoordinatorCoordinatedGraphics::ScrollingCoordinatorCoordinatedGraphics):
1249         (WebCore::ScrollingCoordinatorCoordinatedGraphics::setLayerIsFixedToContainerLayer):
1250         update layer information using existing hook in ScrollingCoordinator.
1251         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h: Added.
1252         (WebCore):
1253         (ScrollingCoordinatorCoordinatedGraphics):
1254         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
1255         (WebCore::CoordinatedGraphicsLayer::setFixedToViewport): now that setting viewport is not
1256         embedded in the synchronization work, we need to mark the layer so it is updated in the
1257         next frame.
1258         (WebCore):
1259         (WebCore::CoordinatedGraphicsLayer::flushCompositingState): remove call to syncFixedLayers().
1260         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
1261         (CoordinatedGraphicsLayerClient): remove now unused syncFixedLayers() from client.
1262         (CoordinatedGraphicsLayer):
1263
1264 2013-02-07  Keishi Hattori  <keishi@webkit.org>
1265
1266         REGRESSION (r140778): Calendar Picker doesn't open when the element has the required attribute
1267         https://bugs.webkit.org/show_bug.cgi?id=109136
1268
1269         Reviewed by Kent Tamura.
1270
1271         Calendar picker was using the "Clear" button to calculate the window width.
1272         Since it doesn't exist when the input element has a required attribute,
1273         it was throwing an error. This patch fixes the width calculating logic.
1274
1275         Tests: platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-required-ar.html
1276                platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-required.html
1277
1278         * Resources/pagepopups/calendarPicker.css:
1279         (.today-clear-area):
1280         * Resources/pagepopups/calendarPicker.js:
1281         (CalendarPicker.prototype.fixWindowSize): Fixing the logic to calculate
1282         the width. We don't want to use clear button because it doesn't exist
1283         when a value is required.
1284
1285 2013-02-07  Gustavo Noronha Silva  <gns@gnome.org>
1286
1287         Unreviewed build fix. libWebCore.la needs to be relinked when
1288         symbols.filter changes.
1289
1290         * GNUmakefile.am: add symbols.filter as a dependency for the
1291         libWebCore.la library.
1292
1293 2013-02-07  Vsevolod Vlasov  <vsevik@chromium.org>
1294
1295         Web Inspector: Closure compilation fixes
1296         https://bugs.webkit.org/show_bug.cgi?id=109131
1297
1298         Reviewed by Yury Semikhatsky.
1299
1300         * inspector/front-end/ElementsPanel.js:
1301         (WebInspector.ElementsPanel):
1302         * inspector/front-end/FileSystemMapping.js:
1303         (WebInspector.FileSystemMappingImpl.prototype.uriPrefixForPathPrefix):
1304         * inspector/front-end/IsolatedFileSystemModel.js:
1305         (WebInspector.IsolatedFileSystemModel.prototype._fileSystemRemoved):
1306         * inspector/front-end/SidebarPane.js:
1307
1308 2013-02-07  Kentaro Hara  <haraken@chromium.org>
1309
1310         Unreviewed, rolling out r142077.
1311         http://trac.webkit.org/changeset/142077
1312         https://bugs.webkit.org/show_bug.cgi?id=108579
1313
1314         fast/filesystem/workers/file-writer-empty-blob.html is broken
1315
1316         * bindings/v8/DOMDataStore.h:
1317         (WebCore::DOMDataStore::setWrapperInObject):
1318         * bindings/v8/DOMWrapperWorld.h:
1319         (DOMWrapperWorld):
1320         (WebCore::DOMWrapperWorld::isolated):
1321         * bindings/v8/V8Binding.h:
1322         (WebCore):
1323         (WebCore::worldForEnteredContextIfIsolated):
1324         * bindings/v8/V8DOMWindowShell.cpp:
1325         (WebCore::V8DOMWindowShell::initializeIfNeeded):
1326         * bindings/v8/V8GCController.cpp:
1327         (WebCore::WrapperVisitor::WrapperVisitor):
1328         (WebCore):
1329         (WebCore::gcTree):
1330         (WebCore::V8GCController::didCreateWrapperForNode):
1331         (WebCore::V8GCController::gcPrologue):
1332         (WebCore::V8GCController::minorGCPrologue):
1333         (WebCore::V8GCController::majorGCPrologue):
1334         * bindings/v8/V8GCController.h:
1335         (V8GCController):
1336
1337 2013-02-07  Tony Gentilcore  <tonyg@chromium.org>
1338
1339         Call XSSAuditor.filterToken() from threaded HTML parser
1340         https://bugs.webkit.org/show_bug.cgi?id=107603
1341
1342         Reviewed by Adam Barth.
1343
1344         With this patch we now pass 180 of 182 tests in http/tests/security/xssAuditor.
1345
1346         We do this by creating aan XSSAuditor on the main thread and passing ownership of them to the BackgroundHTMLParser upon its creation.
1347
1348         Then the background thread calls filterToken() and stores the resulting XSSInfo (if any) on the CompactHTMLToken for the main thread to handle.
1349
1350         This involved trimming the XSSAuditor to only depend on the TextEncoding instead of the whole TextResourceDecoder.
1351
1352         No new tests because covered by existing tests.
1353
1354         * html/parser/BackgroundHTMLParser.cpp:
1355         (WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
1356         (WebCore::BackgroundHTMLParser::pumpTokenizer):
1357         (WebCore::BackgroundHTMLParser::createPartial):
1358         * html/parser/BackgroundHTMLParser.h:
1359         (WebCore):
1360         (WebCore::BackgroundHTMLParser::create):
1361         (BackgroundHTMLParser):
1362         * html/parser/HTMLDocumentParser.cpp:
1363         (WebCore::HTMLDocumentParser::pumpTokenizer):
1364         (WebCore::HTMLDocumentParser::startBackgroundParser):
1365         * html/parser/HTMLSourceTracker.cpp:
1366         (WebCore::HTMLSourceTracker::start):
1367         (WebCore::HTMLSourceTracker::end):
1368         * html/parser/HTMLSourceTracker.h: Change the HTMLInputStream args to SegmentedString because the background thread only has a BackgroundHTMLInputStream.
1369         (HTMLSourceTracker):
1370         * html/parser/HTMLViewSourceParser.cpp:
1371         (WebCore::HTMLViewSourceParser::pumpTokenizer):
1372         * html/parser/XSSAuditor.cpp:
1373         (WebCore::fullyDecodeString):
1374         (WebCore::XSSAuditor::XSSAuditor):
1375         (WebCore::XSSAuditor::init): Copies necessary to make isSafeToSendToAnotherThread() happy.
1376         (WebCore::XSSAuditor::decodedSnippetForName):
1377         (WebCore::XSSAuditor::decodedSnippetForAttribute):
1378         (WebCore::XSSAuditor::decodedSnippetForJavaScript):
1379         (WebCore::XSSAuditor::isSafeToSendToAnotherThread): Check that all String and KURL members are safe to send to another thread.
1380         (WebCore):
1381         * html/parser/XSSAuditor.h:
1382         (WebCore):
1383         (WebCore::FilterTokenRequest::FilterTokenRequest):
1384         (FilterTokenRequest):
1385         (XSSAuditor):
1386
1387 2013-02-07  ChangSeok Oh  <shivamidow@gmail.com>
1388
1389         [GTK][AC] Implement opacity animation with clutter ac backend
1390         https://bugs.webkit.org/show_bug.cgi?id=108961
1391
1392         Reviewed by Gustavo Noronha Silva.
1393
1394         Implement opacity animation with clutter ac backend.
1395         Almost all implementations of GraphicsLayerClutter are based on mac port's one.
1396         PlatformClutterAnimation interfaces are also similar with mac port, but they are implemented
1397         with native clutter APIs.
1398         This patch includes only opacity animation related changes, so many APIs might be empty.
1399         Remained animations like rotation and translate will be dealt in another patches.
1400
1401         Covered by existing animation tests.
1402
1403         * GNUmakefile.list.am:
1404         * platform/graphics/clutter/GraphicsLayerActor.cpp:
1405         (graphicsLayerActorGetAnimationForKey):
1406         * platform/graphics/clutter/GraphicsLayerActor.h:
1407         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
1408         (WebCore):
1409         (WebCore::propertyIdToString):
1410         (WebCore::animationIdentifier):
1411         (WebCore::animationHasStepsTimingFunction):
1412         (WebCore::GraphicsLayerClutter::setOpacity):
1413         (WebCore::GraphicsLayerClutter::updateAnimations):
1414         (WebCore::GraphicsLayerClutter::commitLayerChangesBeforeSublayers):
1415         (WebCore::GraphicsLayerClutter::setupAnimation):
1416         (WebCore::GraphicsLayerClutter::timingFunctionForAnimationValue):
1417         (WebCore::GraphicsLayerClutter::createBasicAnimation):
1418         (WebCore::GraphicsLayerClutter::createKeyframeAnimation):
1419         (WebCore::GraphicsLayerClutter::setTransformAnimationKeyframes):
1420         (WebCore::GraphicsLayerClutter::setTransformAnimationEndpoints):
1421         (WebCore::GraphicsLayerClutter::createTransformAnimationsFromKeyframes):
1422         (WebCore::GraphicsLayerClutter::createAnimationFromKeyframes):
1423         (WebCore::GraphicsLayerClutter::addAnimation):
1424         (WebCore::GraphicsLayerClutter::removeClutterAnimationFromLayer):
1425         (WebCore::GraphicsLayerClutter::pauseClutterAnimationOnLayer):
1426         (WebCore::GraphicsLayerClutter::setAnimationOnLayer):
1427         (WebCore::GraphicsLayerClutter::setAnimationEndpoints):
1428         (WebCore::GraphicsLayerClutter::setAnimationKeyframes):
1429         (WebCore::GraphicsLayerClutter::animatedLayer):
1430         * platform/graphics/clutter/GraphicsLayerClutter.h:
1431         (GraphicsLayerClutter):
1432         (WebCore::GraphicsLayerClutter::LayerPropertyAnimation::LayerPropertyAnimation):
1433         (LayerPropertyAnimation):
1434         (WebCore::GraphicsLayerClutter::AnimationProcessingAction::AnimationProcessingAction):
1435         (AnimationProcessingAction):
1436         * platform/graphics/clutter/PlatformClutterAnimation.cpp: Added.
1437         (WebCore):
1438         (WebCore::timelineStartedCallback):
1439         (WebCore::toClutterAnimationMode):
1440         (WebCore::PlatformClutterAnimation::stringToAnimatedPropertyType):
1441         (WebCore::PlatformClutterAnimation::create):
1442         (WebCore::PlatformClutterAnimation::PlatformClutterAnimation):
1443         (WebCore::PlatformClutterAnimation::~PlatformClutterAnimation):
1444         (WebCore::PlatformClutterAnimation::supportsValueFunction):
1445         (WebCore::PlatformClutterAnimation::beginTime):
1446         (WebCore::PlatformClutterAnimation::setBeginTime):
1447         (WebCore::PlatformClutterAnimation::duration):
1448         (WebCore::PlatformClutterAnimation::setDuration):
1449         (WebCore::PlatformClutterAnimation::speed):
1450         (WebCore::PlatformClutterAnimation::setSpeed):
1451         (WebCore::PlatformClutterAnimation::timeOffset):
1452         (WebCore::PlatformClutterAnimation::setTimeOffset):
1453         (WebCore::PlatformClutterAnimation::repeatCount):
1454         (WebCore::PlatformClutterAnimation::setRepeatCount):
1455         (WebCore::PlatformClutterAnimation::autoreverses):
1456         (WebCore::PlatformClutterAnimation::setAutoreverses):
1457         (WebCore::PlatformClutterAnimation::fillMode):
1458         (WebCore::PlatformClutterAnimation::setFillMode):
1459         (WebCore::PlatformClutterAnimation::setTimingFunction):
1460         (WebCore::PlatformClutterAnimation::copyTimingFunctionFrom):
1461         (WebCore::PlatformClutterAnimation::isRemovedOnCompletion):
1462         (WebCore::PlatformClutterAnimation::setRemovedOnCompletion):
1463         (WebCore::PlatformClutterAnimation::isAdditive):
1464         (WebCore::PlatformClutterAnimation::setAdditive):
1465         (WebCore::PlatformClutterAnimation::valueFunction):
1466         (WebCore::PlatformClutterAnimation::setValueFunction):
1467         (WebCore::PlatformClutterAnimation::setFromValue):
1468         (WebCore::PlatformClutterAnimation::copyFromValueFrom):
1469         (WebCore::PlatformClutterAnimation::setToValue):
1470         (WebCore::PlatformClutterAnimation::copyToValueFrom):
1471         (WebCore::PlatformClutterAnimation::setValues):
1472         (WebCore::PlatformClutterAnimation::copyValuesFrom):
1473         (WebCore::PlatformClutterAnimation::setKeyTimes):
1474         (WebCore::PlatformClutterAnimation::copyKeyTimesFrom):
1475         (WebCore::PlatformClutterAnimation::setTimingFunctions):
1476         (WebCore::PlatformClutterAnimation::copyTimingFunctionsFrom):
1477         (WebCore::PlatformClutterAnimation::animationDidStart):
1478         (WebCore::PlatformClutterAnimation::timeline):
1479         (WebCore::PlatformClutterAnimation::addOpacityTransition):
1480         (WebCore::PlatformClutterAnimation::addAnimationForKey):
1481         (WebCore::PlatformClutterAnimation::removeAnimationForKey):
1482         * platform/graphics/clutter/PlatformClutterAnimation.h: Added.
1483         (WebCore):
1484         (PlatformClutterAnimation):
1485         (WebCore::PlatformClutterAnimation::animationType):
1486
1487 2013-02-07  Andrey Lushnikov  <lushnikov@chromium.org>
1488
1489         Web Inspector: highlight matching braces in DTE.
1490         https://bugs.webkit.org/show_bug.cgi?id=108697
1491
1492         Reviewed by Pavel Feldman.
1493
1494         Implement BraceMatcher class which for given position in textModel
1495         will respond with enclosing brace pair for that position.
1496         Make use of this class in DefaultTextEditor by handling
1497         selectionChange event. Make use of this class in "_closingBlockOffset"
1498         method of TextEditorMainPanel as this method implements similar
1499         functionality.
1500
1501         New test: inspector/editor/brace-matcher.html
1502
1503         * inspector/front-end/DefaultTextEditor.js:
1504         (WebInspector.TextEditorMainPanel):
1505         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
1506         (WebInspector.TextEditorMainPanel.prototype._closingBlockOffset):
1507         (WebInspector.TextEditorMainPanel.prototype._handleSelectionChange):
1508         (WebInspector.TextEditorMainPanel.BraceHighlightController):
1509         (WebInspector.TextEditorMainPanel.BraceHighlightController.prototype.handleSelectionChange):
1510         * inspector/front-end/TextEditorHighlighter.js:
1511         (WebInspector.TextEditorHighlighter.prototype._highlightLines):
1512         * inspector/front-end/TextEditorModel.js:
1513         (WebInspector.TextEditorModel.endsWithBracketRegex):
1514         (WebInspector.TextEditorModel.endsWithBracketRegex.):
1515         * inspector/front-end/textEditor.css:
1516         (.text-editor-brace-match):
1517
1518 2013-02-05  Eunmi Lee  <eunmi15.lee@samsung.com> and Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
1519
1520         [EFL][WK2] Refactoring initialization and shutdown codes of EFL libraries.
1521         https://bugs.webkit.org/show_bug.cgi?id=97173
1522
1523         Reviewed by Kenneth Rohde Christiansen, signed-off by Benjamin Poulain.
1524
1525         Remove codes to initialize and shutdown the EFL libraries from
1526         RunLoopEfl.cpp. Initialization and shutdown will be done in the
1527         ewk_main.cpp for ui process and WebProcessMainEfl.cpp for web
1528         process.
1529
1530         No new tests. This patch doesn't change behavior.
1531
1532         * platform/efl/RunLoopEfl.cpp:
1533         (WebCore::RunLoop::RunLoop):
1534         (WebCore::RunLoop::~RunLoop):
1535
1536 2013-02-07  Ilya Tikhonovsky  <loislo@chromium.org>
1537
1538         Unreviewed fix for inspector tests in debug.
1539         m_frontend should be initialized in constructor.
1540
1541         * inspector/InspectorMemoryAgent.cpp:
1542         (WebCore::InspectorMemoryAgent::InspectorMemoryAgent):
1543
1544 2013-02-07  Yury Semikhatsky  <yurys@chromium.org>
1545
1546         Web Inspector: reduce number of native memory instrumentation categories
1547         https://bugs.webkit.org/show_bug.cgi?id=109146
1548
1549         Reviewed by Pavel Feldman.
1550
1551         Merged some of memory instrumentation categories.
1552
1553         * dom/WebCoreMemoryInstrumentation.cpp:
1554         (WebCore):
1555         * inspector/front-end/NativeMemorySnapshotView.js:
1556         (WebInspector.MemoryBlockViewProperties._initialize):
1557         * platform/PlatformMemoryInstrumentation.cpp:
1558         (WebCore):
1559
1560 2013-02-04  Kentaro Hara  <haraken@chromium.org>
1561
1562         [V8] Remove V8GCController::m_edenNodes and make minor DOM GC more precise
1563         https://bugs.webkit.org/show_bug.cgi?id=108579
1564
1565         Reviewed by Adam Barth.
1566
1567         Currently V8GCController::m_edenNodes stores a list of nodes whose
1568         wrappers have been created since the latest GC. The reason why we
1569         needed m_edenNodes is that there was no way to know a list of wrappers
1570         in the new space of V8. By using m_edenNodes, we had been approximating
1571         'wrappers in the new space' by 'wrappers that have been created since
1572         the latest GC'.
1573
1574         Now V8 provides VisitHandlesForPartialDependence(), with which WebKit
1575         can know a list of wrappers in the new space. By using the API, we can
1576         remove V8GCController::m_edenNodes. The benefit is that (1) we no longer
1577         need to keep m_edenNodes and that (2) it enables more precise minor
1578         DOM GC (Remember that m_edenNodes was just an approximation).
1579
1580         Performance benchmark: https://bugs.webkit.org/attachment.cgi?id=185940
1581         The benchmark runs 300 iterations, each of which creates 100000 elements.
1582         The benchmark measures average, min, median, max and stdev of execution times
1583         of the 300 iterations. This will tell us the worst-case overhead of this change.
1584
1585         Before:
1586           mean=59.91ms, min=39ms, median=42ms, max=258ms, stdev=47.48ms
1587
1588         After:
1589           mean=58.75ms, min=35ms, median=41ms, max=250ms, stdev=47.32ms
1590
1591         As shown above, I couldn't observe any performance regression.
1592
1593         No tests. No change in behavior.
1594
1595         * bindings/v8/DOMDataStore.h:
1596         (WebCore::DOMDataStore::setWrapperInObject):
1597         * bindings/v8/DOMWrapperWorld.h:
1598         (DOMWrapperWorld):
1599         (WebCore::DOMWrapperWorld::getWorldWithoutContextCheck):
1600         * bindings/v8/V8Binding.h:
1601         (WebCore):
1602         (WebCore::worldForEnteredContextIfIsolated):
1603         (WebCore::worldForEnteredContextWithoutContextCheck):
1604         * bindings/v8/V8DOMWindowShell.cpp:
1605         (WebCore::V8DOMWindowShell::initializeIfNeeded):
1606         * bindings/v8/V8GCController.cpp:
1607         (WebCore::gcTree):
1608         (WebCore):
1609         (MinorGCWrapperVisitor):
1610         (WebCore::MinorGCWrapperVisitor::MinorGCWrapperVisitor):
1611         (WebCore::MinorGCWrapperVisitor::notifyFinished):
1612         (WebCore::MajorGCWrapperVisitor::MajorGCWrapperVisitor):
1613         (WebCore::V8GCController::gcPrologue):
1614         (WebCore::V8GCController::minorGCPrologue):
1615         (WebCore::V8GCController::majorGCPrologue):
1616         * bindings/v8/V8GCController.h:
1617         (V8GCController):
1618
1619 2013-02-06  Kent Tamura  <tkent@chromium.org>
1620
1621         REGRESSION(r141195): INPUT_MULTIPLE_FIELDS_UI: Space in a placeholder string is removed
1622         https://bugs.webkit.org/show_bug.cgi?id=109132
1623
1624         Reviewed by Hajime Morita.
1625
1626         <input  type=date> should be shown in Japanese UI as:
1627         [ 年 /月/日]
1628         But it is shown wrongly since r141195:
1629         [年 /月/日]
1630
1631         We should use white-space:pre.
1632
1633         No new tests. This change is not testable in WebKit because this
1634         requires a Japanese-localized UI string of Chromium.
1635
1636         * css/html.css:
1637         (input::-webkit-datetime-edit-fields-wrapper):
1638         Use white-space:pre instead of nowrap.
1639
1640 2013-02-06  Kentaro Hara  <haraken@chromium.org>
1641
1642         Remove DOMWindow::parseModalDialogFeatures()
1643         https://bugs.webkit.org/show_bug.cgi?id=109139
1644
1645         Reviewed by Kent Tamura.
1646
1647         No one uses the method. FIXME is saying:
1648
1649           // FIXME: We can remove this function once V8 showModalDialog is changed to use DOMWindow.
1650
1651         Given that V8's showModalDialog() is now using DOMWindow, we can remove it.
1652
1653         No tests. No change in behavior.
1654
1655         * page/DOMWindow.cpp:
1656         * page/DOMWindow.h:
1657         (DOMWindow):
1658
1659 2013-02-06  Ilya Tikhonovsky  <loislo@chromium.org>
1660
1661         Web Inspector: Native Memory Instrumentation: reduce native heap snapshot runtime memory footprint
1662         https://bugs.webkit.org/show_bug.cgi?id=108824
1663
1664         Reviewed by Yury Semikhatsky.
1665
1666         New event was added into Memory domain addNativeSnapshotChunk.
1667         The content of HeapGraphSerializer is completely rewritten according to new API.
1668         Now it collects strings, nodes, edges and id2id map and pushes when the collected items count exceed a limit.
1669         On the frontend side I added new method for the new event and fixed the postprocessing step.
1670         MemoryInstrumentation was slightly changed. Now it reports base to real address map only after reporting the node with real address.
1671
1672         * inspector/HeapGraphSerializer.cpp:
1673         (WebCore::HeapGraphSerializer::HeapGraphSerializer):
1674         (WebCore::HeapGraphSerializer::pushUpdateIfNeed):
1675         (WebCore):
1676         (WebCore::HeapGraphSerializer::pushUpdate):
1677         (WebCore::HeapGraphSerializer::reportNode):
1678         (WebCore::HeapGraphSerializer::reportNodeImpl):
1679         (WebCore::HeapGraphSerializer::reportEdge):
1680         (WebCore::HeapGraphSerializer::reportEdgeImpl):
1681         (WebCore::HeapGraphSerializer::reportLeaf):
1682         (WebCore::HeapGraphSerializer::reportBaseAddress):
1683         (WebCore::HeapGraphSerializer::finish):
1684         (WebCore::HeapGraphSerializer::reportMemoryUsage):
1685         (WebCore::HeapGraphSerializer::addString):
1686         (WebCore::HeapGraphSerializer::toNodeId):
1687         (WebCore::HeapGraphSerializer::addRootNode):
1688         * inspector/HeapGraphSerializer.h:
1689         (HeapGraphSerializer):
1690         * inspector/Inspector.json:
1691         * inspector/InspectorController.cpp:
1692         (WebCore::InspectorController::processMemoryDistribution):
1693         * inspector/InspectorMemoryAgent.cpp:
1694         (WebCore::InspectorMemoryAgent::getProcessMemoryDistributionMap):
1695         (WebCore):
1696         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
1697         (WebCore::InspectorMemoryAgent::getProcessMemoryDistributionImpl):
1698         (WebCore::InspectorMemoryAgent::setFrontend):
1699         (WebCore::InspectorMemoryAgent::clearFrontend):
1700         * inspector/InspectorMemoryAgent.h:
1701         (InspectorMemoryAgent):
1702         * inspector/front-end/NativeHeapSnapshot.js:
1703         (WebInspector.NativeHeapSnapshot):
1704         (WebInspector.NativeHeapSnapshotNode.prototype.classIndex):
1705         (WebInspector.NativeHeapSnapshotNode.prototype.id):
1706         (WebInspector.NativeHeapSnapshotNode.prototype.name):
1707         (WebInspector.NativeHeapSnapshotNode.prototype.serialize):
1708         * inspector/front-end/NativeMemorySnapshotView.js:
1709         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
1710         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked):
1711         (WebInspector.NativeSnapshotProfileHeader):
1712         (WebInspector.NativeSnapshotProfileHeader.prototype.startSnapshotTransfer):
1713         (WebInspector.NativeSnapshotProfileHeader.prototype.addNativeSnapshotChunk):
1714         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
1715         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked):
1716         (WebInspector.NativeMemoryBarChart.prototype._updateStats):
1717         * inspector/front-end/ProfilesPanel.js:
1718         (WebInspector.ProfilesPanel):
1719         (WebInspector.MemoryDispatcher):
1720         (WebInspector.MemoryDispatcher.prototype.addNativeSnapshotChunk):
1721
1722 2013-02-03  Kentaro Hara  <haraken@chromium.org>
1723
1724         WebKit's focus events are UIEvents (instead of FocusEvent) and thus don't expose .relatedTarget
1725         https://bugs.webkit.org/show_bug.cgi?id=76216
1726
1727         Reviewed by Eric Seidel.
1728
1729         Spec: http://www.w3.org/TR/DOM-Level-3-Events/#events-FocusEvent
1730
1731         This patch creates a new FocusEvent class with a relatedTarget attribute.
1732         Now when focusin or focusout events are dispatched, a FocusEvent is created with
1733         the relatedTarget attribute set accordingly.
1734
1735         Test: fast/events/related-target-focusevent.html
1736
1737         * CMakeLists.txt:
1738         * DerivedSources.cpp:
1739         * DerivedSources.make:
1740         * DerivedSources.pri:
1741         * GNUmakefile.list.am:
1742         * Target.pri:
1743         * WebCore.gypi:
1744         * WebCore.xcodeproj/project.pbxproj:
1745         * dom/DOMAllInOne.cpp:
1746         * dom/Event.cpp:
1747         (WebCore::Event::isFocusEvent):
1748         (WebCore):
1749         * dom/Event.h:
1750         (Event):
1751         * dom/EventContext.cpp:
1752         (WebCore::EventContext::handleLocalEvents):
1753         * dom/EventNames.in:
1754         * dom/FocusEvent.h: Added.
1755         (WebCore):
1756         (FocusEvent):
1757         (WebCore::FocusEvent::create):
1758         (WebCore::FocusEvent::relatedTarget):
1759         (WebCore::FocusEvent::setRelatedTarget):
1760         (WebCore::toFocusEvent):
1761         * dom/FocusEvent.idl: Added.
1762         * dom/Node.cpp:
1763         (WebCore::Node::dispatchFocusInEvent):
1764         (WebCore::Node::dispatchFocusOutEvent):
1765
1766 2013-02-06  Kent Tamura  <tkent@chromium.org>
1767
1768         Fix style of RenderTheme.cpp and RenderThemeChromiumWin.h
1769         https://bugs.webkit.org/show_bug.cgi?id=109137
1770
1771         Reviewed by Kentaro Hara.
1772
1773         No new tests. Just style fix.
1774
1775         * rendering/RenderTheme.cpp:
1776         (WebCore::RenderTheme::adjustStyle):
1777         (WebCore::RenderTheme::paint):
1778         (WebCore::RenderTheme::paintBorderOnly):
1779         (WebCore::RenderTheme::paintDecorations):
1780         (WebCore::RenderTheme::isControlStyled):
1781         (WebCore::RenderTheme::adjustButtonStyle):
1782         (WebCore::RenderTheme::systemColor):
1783         * rendering/RenderThemeChromiumWin.h:
1784         (WebCore::ThemeData::ThemeData):
1785         (ThemeData):
1786         (RenderThemeChromiumWin):
1787         (WebCore::RenderThemeChromiumWin::RenderThemeChromiumWin):
1788         (WebCore::RenderThemeChromiumWin::~RenderThemeChromiumWin):
1789
1790 2013-02-06  Kent Tamura  <tkent@chromium.org>
1791
1792         Fix style of Chrome.h and Page.h
1793         https://bugs.webkit.org/show_bug.cgi?id=109138
1794
1795         Reviewed by Ryosuke Niwa.
1796
1797         No new tests. Just style fixes.
1798
1799         * page/Chrome.h:
1800         (WebCore):
1801         (Chrome):
1802         (WebCore::Chrome::client):
1803         * page/Page.h:
1804         (JSC):
1805         (WebCore):
1806         (WebCore::ArenaSize::ArenaSize):
1807         (ArenaSize):
1808         (Page):
1809         (PageClients):
1810         (WebCore::Page::theme):
1811         (WebCore::Page::canStartMedia):
1812         (WebCore::Page::editorClient):
1813         (WebCore::Page::plugInClient):
1814         (WebCore::Page::mainFrame):
1815         (WebCore::Page::groupPtr):
1816         (WebCore::Page::incrementSubframeCount):
1817         (WebCore::Page::decrementSubframeCount):
1818         (WebCore::Page::subframeCount):
1819         (WebCore::Page::chrome):
1820         (WebCore::Page::dragCaretController):
1821         (WebCore::Page::dragController):
1822         (WebCore::Page::focusController):
1823         (WebCore::Page::contextMenuController):
1824         (WebCore::Page::inspectorController):
1825         (WebCore::Page::pointerLockController):
1826         (WebCore::Page::validationMessageClient):
1827         (WebCore::Page::settings):
1828         (WebCore::Page::progress):
1829         (WebCore::Page::backForward):
1830         (WebCore::Page::featureObserver):
1831         (WebCore::Page::viewMode):
1832         (WebCore::Page::setTabKeyCyclesThroughElements):
1833         (WebCore::Page::tabKeyCyclesThroughElements):
1834         (WebCore::Page::scheduledRunLoopPairs):
1835         (WebCore::Page::defersLoading):
1836         (WebCore::Page::mediaVolume):
1837         (WebCore::Page::pageScaleFactor):
1838         (WebCore::Page::deviceScaleFactor):
1839         (WebCore::Page::shouldSuppressScrollbarAnimations):
1840         (WebCore::Page::pagination):
1841         (WebCore::Page::isOnscreen):
1842         (WebCore::Page::scriptedAnimationsSuspended):
1843         (WebCore::Page::debugger):
1844         (WebCore::Page::hasCustomHTMLTokenizerTimeDelay):
1845         (WebCore::Page::customHTMLTokenizerTimeDelay):
1846         (WebCore::Page::hasCustomHTMLTokenizerChunkSize):
1847         (WebCore::Page::customHTMLTokenizerChunkSize):
1848         (WebCore::Page::areMemoryCacheClientCallsEnabled):
1849         (WebCore::Page::setEditable):
1850         (WebCore::Page::isEditable):
1851         (WebCore::Page::displayID):
1852         (WebCore::Page::layoutMilestones):
1853         (WebCore::Page::setIsPainting):
1854         (WebCore::Page::isPainting):
1855         (WebCore::Page::alternativeTextClient):
1856         (WebCore::Page::checkSubframeCountConsistency):
1857         (WebCore::Page::group):
1858
1859 2013-02-06  Mike West  <mkwst@chromium.org>
1860
1861         Entity-header extension headers honored on 304 responses.
1862         https://bugs.webkit.org/show_bug.cgi?id=72414
1863
1864         Reviewed by Alexey Proskuryakov.
1865
1866         This patch ports Chromium's network stack logic governing header
1867         updates after resource revalidation. Generally, headers sent with 304
1868         responses ought to update the original cached resource's headers.
1869         Certain headers should never be sent with 304 responses, and we should
1870         ignore them if a misconfigured server sends them anyway.
1871
1872         Currently, WebCore ignores all headers prefixed with 'content-'. This
1873         patch adds 'x-content-' and 'x-webkit-' to the list, as well as specific
1874         headers like 'upgrade', 'trailer', and others that the Chromium network
1875         stack currently ignores.
1876
1877         The tests verify that those headers with visible effect are correctly
1878         handled: 'x-frame-options', 'content-security-policy', and
1879         'x-xss-protection'.
1880
1881         Tests: http/tests/security/XFrameOptions/x-frame-options-cached.html
1882                http/tests/security/contentSecurityPolicy/cached-frame-csp.html
1883                http/tests/security/xssAuditor/cached-frame.html
1884
1885         * loader/cache/CachedResource.cpp:
1886         (WebCore):
1887         (WebCore::CachedResource::updateResponseAfterRevalidation):
1888             This patch adds two arrays containing the specific headers to
1889             ignore and the prefixes to ignore. These lists are processed in
1890             shouldUpdateHeaderAfterRevalidation.
1891             CachedResource::updateResponseAfterRevalidation relies on this new
1892             method when processing revalidated resources.
1893
1894         * loader/cache/CachedResource.cpp:
1895         (WebCore):
1896         (WebCore::shouldUpdateHeaderAfterRevalidation):
1897         (WebCore::CachedResource::updateResponseAfterRevalidation):
1898
1899 2013-02-06  Tom Sepez  <tsepez@chromium.org>
1900
1901         document.referrer leakage with XSS Auditor page block
1902         https://bugs.webkit.org/show_bug.cgi?id=109089
1903
1904         Reviewed by Adam Barth.
1905
1906         Pass "about:blank" as referrer instead of "" so that the actual page
1907         is not leaked when empty referrers are replaced later on in the
1908         request.
1909         
1910         * html/parser/XSSAuditorDelegate.cpp:
1911         (WebCore::XSSAuditorDelegate::didBlockScript):
1912
1913 2013-02-06  Kentaro Hara  <haraken@chromium.org>
1914
1915         [V8] Make an Isolate parameter mandatory in GetTemplate() and GetRawTemplate()
1916         https://bugs.webkit.org/show_bug.cgi?id=109026
1917
1918         Reviewed by Adam Barth.
1919
1920         Now it's time to kill an optional Isolate parameter.
1921
1922         No tests. No change in behavior.
1923
1924         * bindings/scripts/CodeGeneratorV8.pm:
1925         (GenerateHeader):
1926         (GenerateNamedConstructorCallback):
1927         (GenerateImplementation):
1928         * bindings/scripts/test/V8/V8Float64Array.cpp:
1929         (WebCore::V8Float64Array::GetRawTemplate):
1930         (WebCore::V8Float64Array::GetTemplate):
1931         * bindings/scripts/test/V8/V8Float64Array.h:
1932         (V8Float64Array):
1933         (WebCore::V8Float64Array::installPerContextPrototypeProperties):
1934         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1935         (WebCore::V8TestActiveDOMObject::GetRawTemplate):
1936         (WebCore::V8TestActiveDOMObject::GetTemplate):
1937         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
1938         (V8TestActiveDOMObject):
1939         (WebCore::V8TestActiveDOMObject::installPerContextPrototypeProperties):
1940         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1941         (WebCore::V8TestCustomNamedGetter::GetRawTemplate):
1942         (WebCore::V8TestCustomNamedGetter::GetTemplate):
1943         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
1944         (V8TestCustomNamedGetter):
1945         (WebCore::V8TestCustomNamedGetter::installPerContextPrototypeProperties):
1946         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1947         (WebCore::V8TestEventConstructor::GetRawTemplate):
1948         (WebCore::V8TestEventConstructor::GetTemplate):
1949         * bindings/scripts/test/V8/V8TestEventConstructor.h:
1950         (V8TestEventConstructor):
1951         (WebCore::V8TestEventConstructor::installPerContextPrototypeProperties):
1952         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1953         (WebCore::V8TestEventTarget::GetRawTemplate):
1954         (WebCore::V8TestEventTarget::GetTemplate):
1955         * bindings/scripts/test/V8/V8TestEventTarget.h:
1956         (V8TestEventTarget):
1957         (WebCore::V8TestEventTarget::installPerContextPrototypeProperties):
1958         * bindings/scripts/test/V8/V8TestException.cpp:
1959         (WebCore::V8TestException::GetRawTemplate):
1960         (WebCore::V8TestException::GetTemplate):
1961         * bindings/scripts/test/V8/V8TestException.h:
1962         (V8TestException):
1963         (WebCore::V8TestException::installPerContextPrototypeProperties):
1964         * bindings/scripts/test/V8/V8TestInterface.cpp:
1965         (WebCore::V8TestInterface::GetRawTemplate):
1966         (WebCore::V8TestInterface::GetTemplate):
1967         * bindings/scripts/test/V8/V8TestInterface.h:
1968         (V8TestInterface):
1969         (WebCore::V8TestInterface::installPerContextPrototypeProperties):
1970         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1971         (WebCore::V8TestMediaQueryListListener::GetRawTemplate):
1972         (WebCore::V8TestMediaQueryListListener::GetTemplate):
1973         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1974         (V8TestMediaQueryListListener):
1975         (WebCore::V8TestMediaQueryListListener::installPerContextPrototypeProperties):
1976         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1977         (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
1978         (WebCore::V8TestNamedConstructor::GetRawTemplate):
1979         (WebCore::V8TestNamedConstructor::GetTemplate):
1980         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
1981         (V8TestNamedConstructor):
1982         (WebCore::V8TestNamedConstructor::installPerContextPrototypeProperties):
1983         * bindings/scripts/test/V8/V8TestNode.cpp:
1984         (WebCore::V8TestNode::GetRawTemplate):
1985         (WebCore::V8TestNode::GetTemplate):
1986         * bindings/scripts/test/V8/V8TestNode.h:
1987         (V8TestNode):
1988         (WebCore::V8TestNode::installPerContextPrototypeProperties):
1989         * bindings/scripts/test/V8/V8TestObj.cpp:
1990         (WebCore::V8TestObj::GetRawTemplate):
1991         (WebCore::V8TestObj::GetTemplate):
1992         (WebCore::V8TestObj::installPerContextPrototypeProperties):
1993         * bindings/scripts/test/V8/V8TestObj.h:
1994         (V8TestObj):
1995         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
1996         (WebCore::V8TestOverloadedConstructors::GetRawTemplate):
1997         (WebCore::V8TestOverloadedConstructors::GetTemplate):
1998         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
1999         (V8TestOverloadedConstructors):
2000         (WebCore::V8TestOverloadedConstructors::installPerContextPrototypeProperties):
2001         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2002         (WebCore::V8TestSerializedScriptValueInterface::GetRawTemplate):
2003         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
2004         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2005         (V8TestSerializedScriptValueInterface):
2006         (WebCore::V8TestSerializedScriptValueInterface::installPerContextPrototypeProperties):
2007         * bindings/v8/V8PerContextData.cpp:
2008         (WebCore::V8PerContextData::constructorForTypeSlowCase):
2009         * bindings/v8/WrapperTypeInfo.h:
2010         (WebCore):
2011         (WebCore::WrapperTypeInfo::installPerContextPrototypeProperties):
2012
2013 2013-02-06  Terry Anderson  <tdanderson@chromium.org>
2014
2015         Add support for gesture scroll events that do not propagate to enclosing scrollables
2016         https://bugs.webkit.org/show_bug.cgi?id=108849
2017
2018         Reviewed by Antonio Gomes.
2019
2020         Tests: fast/events/touch/gesture/touch-gesture-scroll-div-not-propagated.html
2021                fast/events/touch/gesture/touch-gesture-scroll-iframe-not-propagated.html
2022                fast/events/touch/gesture/touch-gesture-scroll-page-not-propagated.html
2023
2024         Rename RenderLayer::scrollByRecursively() to RenderLayer::scrollBy() and add a parameter
2025         of type RenderLayer::ScrollPropagation to specify whether or not the scroll should
2026         propagate to its parent by recursing. Implement RenderLayer::scrollByRecursively() as a
2027         call to RenderLayer::scrollBy() with argument RenderLayer::ShouldPropagateScroll so
2028         that all existing calls to the function still produce the correct behavior.
2029
2030         In EventHandler::handleGestureScrollUpdate(), call RenderLayer::scrollBy() with
2031         argument RenderLayer::ShouldPropagateScroll if |gestureEvent| is a GestureScrollUpdate
2032         or instead with argument RenderLayer::DontPropagateScroll if |gestureEvent| is a
2033         GestureScrollUpdateWithoutPropagation.
2034
2035         * dom/GestureEvent.cpp:
2036         (WebCore::GestureEvent::create):
2037         * page/EventHandler.cpp:
2038         (WebCore::EventHandler::handleGestureEvent):
2039         (WebCore::EventHandler::handleGestureScrollUpdate):
2040         * platform/PlatformEvent.h:
2041         * platform/Scrollbar.cpp:
2042         (WebCore::Scrollbar::gestureEvent):
2043         * platform/chromium/PopupContainer.cpp:
2044         (WebCore::PopupContainer::handleGestureEvent):
2045         * rendering/RenderLayer.cpp:
2046         (WebCore::RenderLayer::scrollByRecursively):
2047         (WebCore):
2048         (WebCore::RenderLayer::scrollBy):
2049         * rendering/RenderLayer.h:
2050
2051 2013-02-06  Ojan Vafai  <ojan@chromium.org>
2052
2053         [Chromium] table-section-overflow-clip-crash.html hits an assert
2054         https://bugs.webkit.org/show_bug.cgi?id=108594
2055
2056         Reviewed by Levi Weintraub.
2057
2058         When a counter calls setNeedsLayout, it also marks it's containing blocks
2059         as needing layout, so we need to clear the setNeedsLayoutIsForbidden bit on the
2060         containing blocks as well as the counter itself.
2061
2062         Also, use RAII objects for all the places where we clear this bit and make
2063         the setter/getter for it private to RenderObject.
2064
2065         * rendering/RenderCounter.cpp:
2066         (WebCore::RenderCounter::computePreferredLogicalWidths):
2067         * rendering/RenderObject.cpp:
2068         (WebCore::RenderObject::SetLayoutNeededForbiddenScope::SetLayoutNeededForbiddenScope):
2069         (WebCore::RenderObject::markContainingBlocksForLayout):
2070         * rendering/RenderObject.h:
2071         (SetLayoutNeededForbiddenScope):
2072         (RenderObject):
2073         (WebCore::RenderObject::isSetNeedsLayoutForbidden):
2074         (WebCore::RenderObject::setNeedsLayoutIsForbidden):
2075         * rendering/RenderQuote.cpp:
2076         (WebCore::RenderQuote::computePreferredLogicalWidths):
2077         * rendering/RenderTableSection.cpp:
2078         (WebCore::RenderTableSection::calcRowLogicalHeight):
2079         (WebCore::RenderTableSection::layoutRows):
2080         * rendering/mathml/RenderMathMLOperator.cpp:
2081         (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
2082         * rendering/mathml/RenderMathMLRoot.cpp:
2083         (WebCore::RenderMathMLRoot::computePreferredLogicalWidths):
2084         * rendering/mathml/RenderMathMLRow.cpp:
2085         (WebCore::RenderMathMLRow::computePreferredLogicalWidths):
2086
2087 2013-02-06  Ojan Vafai  <ojan@chromium.org>
2088
2089         display:none file upload button crashes
2090         https://bugs.webkit.org/show_bug.cgi?id=109102
2091
2092         Reviewed by Levi Weintraub.
2093
2094         Test: fast/forms/file/display-none-upload-button.html
2095
2096         * rendering/RenderFileUploadControl.cpp:
2097         (WebCore::nodeWidth):
2098         (WebCore::RenderFileUploadControl::paintObject):
2099         Having an upload button doesn't mean we have a rendered upload button.
2100         Null check the renderer before trying to access it.
2101
2102 2013-02-06  Dirk Schulze  <dschulze@adobe.com>
2103
2104         Context's currentPath should check for passed type
2105         https://bugs.webkit.org/show_bug.cgi?id=109097
2106
2107         Reviewed by Dean Jackson.
2108
2109         Add check for passed pointer and return earlier.
2110
2111         Test: fast/canvas/canvas-currentPath-crash.html
2112
2113         * html/canvas/CanvasRenderingContext2D.cpp:
2114         (WebCore::CanvasRenderingContext2D::setCurrentPath):
2115
2116 2013-02-06  Rafael Weinstein  <rafaelw@chromium.org>
2117
2118         [HTMLTemplateElement] Non </template> end tags should be ignored in "template contents" insertion mode.
2119         https://bugs.webkit.org/show_bug.cgi?id=109090
2120
2121         Reviewed by Adam Barth.
2122
2123         https://dvcs.w3.org/hg/webcomponents/raw-file/38536d37fb82/spec/templates/index.html#template-contents-insertion-mode.
2124
2125         Test added to html5lib suite.
2126
2127         * html/parser/HTMLTreeBuilder.cpp:
2128         (WebCore::HTMLTreeBuilder::processEndTag):
2129
2130 2013-02-06  Alexandre Elias  <aelias@chromium.org>
2131
2132         Make ScrollView::paint() clip by visibleContentRect
2133         https://bugs.webkit.org/show_bug.cgi?id=108888
2134
2135         Reviewed by Levi Weintraub.
2136
2137         When applyPageScaleFactorInCompositor or fixedVisibleContentRect
2138         are used, frameRect() and visibleContentRect(true).size() are
2139         no longer synonyms, and the latter is the one that should be
2140         used for clipping paints.
2141
2142         New WebFrameTest: pageScaleFactorScalesPaintClip.
2143
2144         * platform/ScrollView.cpp:
2145         (WebCore::ScrollView::paint):
2146
2147 2013-02-06  Dima Gorbik  <dgorbik@apple.com>
2148
2149         Store the language internally instead of using lang attribute for WebVTT nodes
2150         https://bugs.webkit.org/show_bug.cgi?id=108858
2151
2152         Reviewed by Eric Carlson.
2153
2154         Only language webvtt elements should have a lang attribute so we have to store
2155         the language internally in the element. Refactored the code to make 
2156         computeInheritedLanguage virtual.
2157
2158         Existing tests were modified to cover this case.
2159
2160         * css/SelectorChecker.cpp:
2161         (WebCore::SelectorChecker::checkOne):
2162         * html/track/WebVTTElement.cpp:
2163         (WebCore::WebVTTElement::WebVTTElement):
2164         (WebCore::WebVTTElement::cloneElementWithoutAttributesAndChildren):
2165         (WebCore::WebVTTElement::createEquivalentHTMLElement): clone the internal language property.
2166         * html/track/WebVTTElement.h:
2167         (WebCore::WebVTTElement::language):
2168         (WebCore::WebVTTElement::setLanguage):
2169         * html/track/WebVTTParser.cpp: only set the lang attribute for language objects.
2170         (WebCore::WebVTTParser::constructTreeFromToken):
2171
2172 2013-02-06  Levi Weintraub  <leviw@chromium.org>
2173
2174         Negative text indents can break RenderBlock's inline maximum preferred width calculation
2175         https://bugs.webkit.org/show_bug.cgi?id=108973
2176
2177         Reviewed by Emil A Eklund.
2178
2179         Change two quirks about to how we calculate a block's inline preferred width with
2180         text-indent.
2181
2182         First, re-use text-indent that's first applied to floats on text that follows it.
2183         This matches Layout, as otherwise we can prematurely wrap text when there's a negative
2184         margin on a block starting with a float. This also matches FireFox.
2185
2186         Second, correct how the max preferred width is calculated in the presence of a negative
2187         text-indent. If the text-indent is more negative than the first text line break, we
2188         update the value to be the remainder. Previously, we added this remaining negative value
2189         to subsequent minimum and maximum preferred width calculations (until the remainder was
2190         gone). This is wrong for the max preferred width, as we're adding the negative value more
2191         than once, and leads to a max preferred width that's smaller than our line.
2192
2193         Test: fast/css/negative-text-indent-in-inline-block.html
2194
2195         * rendering/RenderBlock.cpp:
2196         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
2197
2198 2013-02-06  Mark Lam  <mark.lam@apple.com>
2199
2200         Fix broken release builds, greening the bots.
2201         https://bugs.webkit.org/show_bug.cgi?id=107475.
2202
2203         Not reviewed.
2204
2205         No new tests.
2206
2207         * Modules/webdatabase/DatabaseManager.cpp:
2208         (WebCore::logOpenDatabaseError):
2209
2210 2013-02-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2211
2212         Unreviewed, rolling out r142025.
2213         http://trac.webkit.org/changeset/142025
2214         https://bugs.webkit.org/show_bug.cgi?id=109091
2215
2216         broke the build (Requested by tdanderson on #webkit).
2217
2218         * dom/GestureEvent.cpp:
2219         (WebCore::GestureEvent::create):
2220         * page/EventHandler.cpp:
2221         (WebCore::EventHandler::handleGestureEvent):
2222         (WebCore::EventHandler::handleGestureScrollUpdate):
2223         * platform/PlatformEvent.h:
2224         * platform/Scrollbar.cpp:
2225         (WebCore::Scrollbar::gestureEvent):
2226         * platform/chromium/PopupContainer.cpp:
2227         (WebCore::PopupContainer::handleGestureEvent):
2228         * rendering/RenderLayer.cpp:
2229         (WebCore::RenderLayer::scrollByRecursively):
2230         * rendering/RenderLayer.h:
2231
2232 2013-02-06  Mark Lam  <mark.lam@apple.com>
2233
2234         Split openDatabase() between front and back end work.
2235         https://bugs.webkit.org/show_bug.cgi?id=107475.
2236
2237         Reviewed by Anders Carlsson.
2238
2239         The main work of splitting DatabaseManager::openDatabase() is in
2240         refactoring how DatabaseTracker::canEstablishDatabase() works. It used
2241         to check for adequate space quota, and if the check fails, it would call
2242         back into the client from inside canEstablishDatabase(). The call back
2243         allows the client to update the quota (if appropriate). Thereafter,
2244         canEstablishDatabase() will retry its quota check.
2245
2246         In a webkit2 world, we'll want to minimize the traffic between the
2247         client (script side) and the server (sqlite db side), and ideally, we
2248         don't want the server to call back to the client. Note: the
2249         DatabaseTracker belongs on the server side.
2250
2251         To achieve this, we split canEstablishDatabase() into 2 parts: the
2252         checks before the call back to the client, and the checks after.
2253         The first part will retain the name canEstablishDatabase(), and the
2254         second part will be named retryCanEstablishDatabase().
2255         We also added a DatabaseServer::openDatabase() function that can be
2256         called with a retry flag.
2257
2258         The client side DatabaseManager::openDatabase() will call
2259         DatabaseServer::openDatabase(), which then calls canEstablishDatabase()
2260         to do its quota check. If there is enough quota,
2261         DatabaseServer::openDatabase() will proceed to open the backend database
2262         without return to the client first. The opened database will be returned
2263         to the client.
2264
2265         If DatabaseServer::openDatabase() finds inadequate quota the first time,
2266         it will return with a DatabaseSizeExceededQuota error. The DatabaseManager
2267         (on the client side) will check for this error and call back to its client
2268         for an opportunity to increase the quota. Thereafter, the DatabaseManager
2269         will call DatabaseServer::openDatabase() again. This time,
2270         DatabaseServer::openDatabase() will call retryCanEstablishDatabase() to
2271         check the quota, and then open the backend database if there is enough
2272         quota.
2273
2274         No new tests.
2275
2276         * Modules/webdatabase/AbstractDatabaseServer.h:
2277         * Modules/webdatabase/DOMWindowWebDatabase.cpp:
2278         (WebCore::DOMWindowWebDatabase::openDatabase):
2279         * Modules/webdatabase/Database.cpp:
2280         (WebCore::Database::create):
2281         * Modules/webdatabase/Database.h:
2282         (Database):
2283         * Modules/webdatabase/DatabaseBackend.cpp:
2284         (WebCore::DatabaseBackend::performOpenAndVerify):
2285         * Modules/webdatabase/DatabaseBackend.h:
2286         (DatabaseBackend):
2287         * Modules/webdatabase/DatabaseBackendAsync.cpp:
2288         (WebCore::DatabaseBackendAsync::openAndVerifyVersion):
2289         (WebCore::DatabaseBackendAsync::performOpenAndVerify):
2290         * Modules/webdatabase/DatabaseBackendAsync.h:
2291         (DatabaseBackendAsync):
2292         * Modules/webdatabase/DatabaseBackendSync.cpp:
2293         (WebCore::DatabaseBackendSync::openAndVerifyVersion):
2294         * Modules/webdatabase/DatabaseBackendSync.h:
2295         (DatabaseBackendSync):
2296         * Modules/webdatabase/DatabaseError.h:
2297         (WebCore::ENUM_CLASS):
2298         * Modules/webdatabase/DatabaseManager.cpp:
2299         (WebCore::DatabaseManager::exceptionCodeForDatabaseError):
2300         (WebCore::DatabaseManager::openDatabaseBackend):
2301         (WebCore::DatabaseManager::openDatabase):
2302         (WebCore::DatabaseManager::openDatabaseSync):
2303         * Modules/webdatabase/DatabaseManager.h:
2304         (DatabaseManager):
2305         * Modules/webdatabase/DatabaseServer.cpp:
2306         (WebCore::DatabaseServer::openDatabase):
2307         (WebCore::DatabaseServer::createDatabase):
2308         * Modules/webdatabase/DatabaseServer.h:
2309         * Modules/webdatabase/DatabaseSync.cpp:
2310         (WebCore::DatabaseSync::create):
2311         * Modules/webdatabase/DatabaseSync.h:
2312         (DatabaseSync):
2313         * Modules/webdatabase/DatabaseTracker.cpp:
2314         (WebCore::DatabaseTracker::hasAdequateQuotaForOrigin):
2315         (WebCore::DatabaseTracker::canEstablishDatabase):
2316         (WebCore::DatabaseTracker::retryCanEstablishDatabase):
2317         * Modules/webdatabase/DatabaseTracker.h:
2318         (DatabaseTracker):
2319         * Modules/webdatabase/WorkerContextWebDatabase.cpp:
2320         (WebCore::WorkerContextWebDatabase::openDatabase):
2321         (WebCore::WorkerContextWebDatabase::openDatabaseSync):
2322         * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
2323         (WebCore::DatabaseTracker::canEstablishDatabase):
2324         (WebCore::DatabaseTracker::retryCanEstablishDatabase):
2325
2326 2013-02-06  Tony Gentilcore  <tonyg@chromium.org>
2327
2328         Fix CompactHTMLToken's copy ctor to copy all fields
2329         https://bugs.webkit.org/show_bug.cgi?id=109076
2330
2331         Reviewed by Adam Barth.
2332
2333         This was introduced by me in r142004. Without this patch we fail all tests when using the background parser.
2334
2335         Also don't use getters in copy ctor.
2336
2337         No new tests because no new functionality.
2338
2339         * html/parser/CompactHTMLToken.cpp:
2340         (WebCore::CompactHTMLToken::CompactHTMLToken):
2341
2342 2013-02-06  Brian Salomon  <bsalomon@google.com>
2343
2344         [Chromium/Skia] Remove use of deprecated Skia names
2345         https://bugs.webkit.org/show_bug.cgi?id=109085
2346
2347         Reviewed by Stephen White.
2348
2349         Tested by every existing canvas2d test.
2350
2351         * platform/chromium/support/GraphicsContext3DPrivate.cpp:
2352         (WebCore::GraphicsContext3DPrivate::grContext):
2353
2354 2013-02-06  Terry Anderson  <tdanderson@chromium.org>
2355
2356         Add support for gesture scroll events that do not propagate to enclosing scrollables
2357         https://bugs.webkit.org/show_bug.cgi?id=108849
2358
2359         Reviewed by Antonio Gomes.
2360
2361         Tests: fast/events/touch/gesture/touch-gesture-scroll-div-not-propagated.html
2362                fast/events/touch/gesture/touch-gesture-scroll-iframe-not-propagated.html
2363                fast/events/touch/gesture/touch-gesture-scroll-page-not-propagated.html
2364
2365         Rename RenderLayer::scrollByRecursively() to RenderLayer::scrollBy() and add a parameter
2366         of type RenderLayer::ScrollPropagation to specify whether or not the scroll should
2367         propagate to its parent by recursing. Implement RenderLayer::scrollByRecursively() as a
2368         call to RenderLayer::scrollBy() with argument RenderLayer::ShouldPropagateScroll so
2369         that all existing calls to the function still produce the correct behavior.
2370
2371         In EventHandler::handleGestureScrollUpdate(), call RenderLayer::scrollBy() with
2372         argument RenderLayer::ShouldPropagateScroll if |gestureEvent| is a GestureScrollUpdate
2373         or instead with argument RenderLayer::DontPropagateScroll if |gestureEvent| is a
2374         GestureScrollUpdateWithoutPropagation.
2375
2376         * dom/GestureEvent.cpp:
2377         (WebCore::GestureEvent::create):
2378         * page/EventHandler.cpp:
2379         (WebCore::EventHandler::handleGestureEvent):
2380         (WebCore::EventHandler::handleGestureScrollUpdate):
2381         * platform/PlatformEvent.h:
2382         * platform/Scrollbar.cpp:
2383         (WebCore::Scrollbar::gestureEvent):
2384         * platform/chromium/PopupContainer.cpp:
2385         (WebCore::PopupContainer::handleGestureEvent):
2386         * rendering/RenderLayer.cpp:
2387         (WebCore::RenderLayer::scrollByRecursively):
2388         (WebCore):
2389         (WebCore::RenderLayer::scrollBy):
2390         * rendering/RenderLayer.h:
2391
2392 2013-02-06  Ryosuke Niwa  <rniwa@webkit.org>
2393
2394         REGRESSION(r141136): Apple's internal PLT test suite doesn't finish
2395         https://bugs.webkit.org/show_bug.cgi?id=108380
2396
2397         Reviewed by Alexey Proskuryakov.
2398
2399         Re-enable the main resource cache since the regression had been fixed in r141615.
2400
2401         * loader/cache/CachedResourceLoader.cpp:
2402         (WebCore::CachedResourceLoader::requestResource):
2403
2404 2013-02-06  Uday Kiran  <udaykiran@motorola.com>
2405
2406         Implement 'vmax' from CSS3 values and units
2407         https://bugs.webkit.org/show_bug.cgi?id=91440
2408
2409         Reviewed by Antti Koivisto.
2410
2411         vmax is implemented as primitive length unit.
2412         New length type ViewportPercentageMax is added and included support for fetching the value
2413         of this viewport percentage unit based on current viewport size.
2414
2415         The specification related to this implementation is
2416         http://dev.w3.org/csswg/css3-values/#viewport-relative-lengths.
2417
2418         Tests: css3/viewport-percentage-lengths/css3-viewport-percentage-lengths-vmax-absolute.html
2419                css3/viewport-percentage-lengths/css3-viewport-percentage-lengths-vmax.html
2420
2421         * css/CSSGrammar.y.in: Added vmax support.
2422         * css/CSSParser.cpp: Parsing of vmax unit.
2423         (WebCore::CSSParser::validUnit): Added vmax to valid units.
2424         (WebCore::CSSParser::createPrimitiveNumericValue): Added vmax to primitive untis.
2425         (WebCore::CSSParser::parseValidPrimitive): Creation of CSSPrimitive for vmax.
2426         (WebCore::CSSParser::detectNumberToken): Parsing of vmax token.
2427         * css/CSSParserValues.cpp:
2428         (WebCore::CSSParserValue::createCSSValue): Added support for vmax.
2429         * css/CSSPrimitiveValue.cpp:
2430         (WebCore::isValidCSSUnitTypeForDoubleConversion): Added support for vmax.
2431         (WebCore::unitCategory): Ditto.
2432         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Ditto.
2433         (WebCore::CSSPrimitiveValue::cleanup):
2434         (WebCore::CSSPrimitiveValue::customCssText): Added support for vmax.
2435         (WebCore::CSSPrimitiveValue::viewportPercentageLength): Function to create the Length structure for the viewport-percentage unit types.
2436         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
2437         * css/CSSPrimitiveValue.h:
2438         (WebCore::CSSPrimitiveValue::isViewportPercentageLength): Checks whether the primitive value is ViewportPercentage Length.
2439         * css/CSSPrimitiveValue.idl: Added support for vmax.
2440         * css/LengthFunctions.cpp: Calcuation of length value based on the current viewport size.
2441         (WebCore::minimumValueForLength):
2442         (WebCore::valueForLength):
2443         (WebCore::floatValueForLength):
2444         * platform/Length.h:
2445         (WebCore::Length::isViewportPercentage): To check the Length is of type ViewportPercentage.
2446         * rendering/RenderBox.cpp:
2447         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
2448         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2449
2450 2013-02-06  Pravin D  <pravind.2k4@gmail.com>
2451
2452         When a block element is made inline positioned and has static left and right,  it does not follow inline formatting context
2453         https://bugs.webkit.org/show_bug.cgi?id=91665
2454
2455         Reviewed by Julien Chaffraix.
2456
2457         Out-of-flow-positioned elements have their display overriden to BLOCK. When a static block elements 
2458         changes to inline out-of-flow-positioned or vice-versa, the element current and previous display properties 
2459         are same. This causes the element to follow a wrong flow context(in this case Block context) and the element
2460         is laid out incorrectly. The patch fixes the issue by reattaching the renderers of the node whenever either
2461         position property changes or when its floating property changes.
2462         Also the cases when an out-of-flow-positioned/floating element changes to static/non-floating element where
2463         being specially handled. As reattaching the renderers in the above cases correctly handles the above cases,
2464         special handling for such cases is no more required and the related code can be safely removed.
2465  
2466         Reattaching renderers for the afore mentioned issues takes a different(longer) code path. Performance measurements
2467         summary for the same is as follows:
2468                                                               % increase in time
2469          Absolute-block-to-static-block                            2.00
2470          Absolute-inline-to-static-block                           1.21
2471          Absolute-inline-to-static-inline                          1.18
2472          Static-block-to-absolute-block                            1.13
2473          Static-inline-to-absolute-inline                          1.35
2474          Floating-block-non-floating-block                         0.85
2475          Floating-inline-non-floating-block                        0.66
2476          Floating-inline-non-floating-inline                       0.57
2477          Non-floating-block-floating-block                         0.12
2478          Non-floating-inline-floating-inline                       1.36
2479
2480         Tests: fast/dynamic/absolute-positioned-to-static-positioned.html
2481                fast/dynamic/floating-to-non-floating.html
2482                fast/dynamic/non-floating-to-floating.html
2483                fast/dynamic/static-positioned-to-absolute-positioned.html
2484
2485         * dom/Node.cpp:
2486         (WebCore::Node::diff):
2487           Return detach in the following conditions:
2488              1) Element changes to out-of-flow-positioned or vice-versa.
2489              2) Element becomes floating or vice-versa.
2490
2491         * rendering/RenderBlock.cpp:
2492         (WebCore):
2493         * rendering/RenderBlock.h:
2494         (RenderBlock):
2495         * rendering/RenderBoxModelObject.h:
2496         (RenderBoxModelObject):
2497         * rendering/RenderInline.cpp:
2498         (WebCore):
2499         * rendering/RenderInline.h:
2500         (RenderInline):
2501         * rendering/RenderObject.cpp:
2502         (WebCore):
2503         (WebCore::RenderObject::styleWillChange):
2504         (WebCore::RenderObject::styleDidChange):
2505         * rendering/RenderObject.h:
2506         (RenderObject):
2507           The fix in Node::diff() obsoletes some code. The above deletion are part of this dead code cleanup.
2508
2509 2013-02-06  Chris Fleizach  <cfleizach@apple.com>
2510
2511         AX: if <html> has an ARIA attribute, it's exposed as an AXGroup
2512         https://bugs.webkit.org/show_bug.cgi?id=109008
2513
2514         Reviewed by Ryosuke Niwa.
2515
2516         If an <html> element had an ARIA attribute, it was being turned into an element
2517         in the AX hierarchy. This was causing trouble for screen readers by inserting
2518         an unexpected element in the navigation sequence.
2519
2520         Test: accessibility/html-html-element-is-ignored.html
2521
2522         * accessibility/AccessibilityRenderObject.cpp:
2523         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
2524
2525 2013-02-06  Shawn Singh  <shawnsingh@chromium.org>
2526
2527         RenderLayer hasVisibleContent() has inconsistent semantics causing disappearing composited layers
2528         https://bugs.webkit.org/show_bug.cgi?id=108118
2529
2530         Reviewed by Simon Fraser.
2531
2532         RenderLayerBacking::hasVisibleNonCompositingDescendantLayers was
2533         only checking whether direct children had visible content. As a
2534         result, composited layers had wrong visibility status if only a
2535         deeper descendant RenderLayer was visible.
2536
2537         Test: compositing/visibility/visibility-on-distant-descendant.html
2538
2539         * rendering/RenderLayerBacking.cpp:
2540         (WebCore::hasVisibleNonCompositingDescendant): copied the original
2541         implementation into this function; then added the RenderLayer
2542         recursion as appropriate.
2543         (WebCore):
2544         (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers):
2545         This is now just a wrapper to the private static recursive
2546         function.
2547
2548 2013-02-06  Jonathon Jongsma  <jonathon.jongsma@collabora.com>
2549
2550         [GStreamer] MediaPlayer's code is not easily reusable by other GStreamer-based players
2551         https://bugs.webkit.org/show_bug.cgi?id=100261
2552
2553         Refactor the media player implementation so that more of the
2554         internal functionality can be shared between the current media
2555         backend and the mediastream player backend.  Common code is
2556         broken out into a MediaPlayerPrivateGStreamerBase class, and
2557         both MediaPlayerPrivateGStreamer and
2558         StreamMediaPlayerPrivateGStreamer inherit from this base class.
2559
2560         Reviewed by Philippe Normand
2561
2562         No new tests since functionality is covered by existing media tests
2563
2564         * GNUmakefile.list.am:
2565         * PlatformEfl.cmake:
2566         * Target.pri:
2567         * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.cpp:
2568         (WebCore::FullscreenVideoControllerGStreamer::create):
2569         (WebCore::FullscreenVideoControllerGStreamer::FullscreenVideoControllerGStreamer):
2570         * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.h:
2571         (WebCore):
2572         (FullscreenVideoControllerGStreamer):
2573         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2574         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
2575         (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
2576         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
2577         (MediaPlayerPrivateGStreamer):
2578         (WebCore::MediaPlayerPrivateGStreamer::isLiveStream):
2579         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: Added.
2580         (WebCore):
2581         (WebCore::greatestCommonDivisor):
2582         (WebCore::mediaPlayerPrivateVolumeChangedCallback):
2583         (WebCore::mediaPlayerPrivateVolumeChangeTimeoutCallback):
2584         (WebCore::mediaPlayerPrivateMuteChangedCallback):
2585         (WebCore::mediaPlayerPrivateMuteChangeTimeoutCallback):
2586         (WebCore::mediaPlayerPrivateRepaintCallback):
2587         (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
2588         (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
2589         (WebCore::MediaPlayerPrivateGStreamerBase::naturalSize):
2590         (WebCore::MediaPlayerPrivateGStreamerBase::setVolume):
2591         (WebCore::MediaPlayerPrivateGStreamerBase::volume):
2592         (WebCore::MediaPlayerPrivateGStreamerBase::notifyPlayerOfVolumeChange):
2593         (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
2594         (WebCore::MediaPlayerPrivateGStreamerBase::networkState):
2595         (WebCore::MediaPlayerPrivateGStreamerBase::readyState):
2596         (WebCore::MediaPlayerPrivateGStreamerBase::sizeChanged):
2597         (WebCore::MediaPlayerPrivateGStreamerBase::setMuted):
2598         (WebCore::MediaPlayerPrivateGStreamerBase::muted):
2599         (WebCore::MediaPlayerPrivateGStreamerBase::notifyPlayerOfMute):
2600         (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
2601         (WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
2602         (WebCore::MediaPlayerPrivateGStreamerBase::setSize):
2603         (WebCore::MediaPlayerPrivateGStreamerBase::paint):
2604         (WebCore::MediaPlayerPrivateGStreamerBase::enterFullscreen):
2605         (WebCore::MediaPlayerPrivateGStreamerBase::exitFullscreen):
2606         (WebCore::MediaPlayerPrivateGStreamerBase::supportsFullscreen):
2607         (WebCore::MediaPlayerPrivateGStreamerBase::platformMedia):
2608         (WebCore::MediaPlayerPrivateGStreamerBase::movieLoadType):
2609         (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink):
2610         (WebCore::MediaPlayerPrivateGStreamerBase::setStreamVolumeElement):
2611         (WebCore::MediaPlayerPrivateGStreamerBase::decodedFrameCount):
2612         (WebCore::MediaPlayerPrivateGStreamerBase::droppedFrameCount):
2613         (WebCore::MediaPlayerPrivateGStreamerBase::audioDecodedByteCount):
2614         (WebCore::MediaPlayerPrivateGStreamerBase::videoDecodedByteCount):
2615         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: Added.
2616         (WebCore):
2617         (MediaPlayerPrivateGStreamerBase):
2618         (WebCore::MediaPlayerPrivateGStreamerBase::supportsMuting):
2619         (WebCore::MediaPlayerPrivateGStreamerBase::setVisible):
2620         (WebCore::MediaPlayerPrivateGStreamerBase::hasSingleSecurityOrigin):
2621         (WebCore::MediaPlayerPrivateGStreamerBase::maxTimeLoaded):
2622         (WebCore::MediaPlayerPrivateGStreamerBase::canEnterFullscreen):
2623         (WebCore::MediaPlayerPrivateGStreamerBase::mediaPlayer):
2624         (WebCore::MediaPlayerPrivateGStreamerBase::audioSink):
2625         * platform/graphics/gtk/FullscreenVideoControllerGtk.cpp:
2626         (WebCore::FullscreenVideoControllerGtk::FullscreenVideoControllerGtk):
2627         * platform/graphics/gtk/FullscreenVideoControllerGtk.h:
2628         (FullscreenVideoControllerGtk):
2629
2630 2013-02-06  Tony Gentilcore  <tonyg@chromium.org>
2631
2632         Call XSSAuditor's didBlockScript() for the threaded HTML parser
2633         https://bugs.webkit.org/show_bug.cgi?id=108726
2634
2635         Reviewed by Adam Barth.
2636
2637         This patch causes us to call didBlockScript() on the main thread if the CompactHTML token has XSSInfo.
2638         To do so, we:
2639         1. Rename DidBlockScriptRequest to XSSInfo.
2640         2. Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
2641         3. Add an isSafeToSendToAnotherThread() method to String and KURL.
2642
2643         We don't yet populate didBlockScriptRequest on the background thread, but this should just work once we do.
2644
2645         No new tests because no new functionality.
2646
2647         * html/parser/BackgroundHTMLParser.cpp:
2648         (WebCore::BackgroundHTMLParser::pumpTokenizer): Update comment for rename.
2649         * html/parser/CompactHTMLToken.cpp:
2650         (SameSizeAsCompactHTMLToken):
2651         (WebCore::CompactHTMLToken::CompactHTMLToken): Add a copy constructor used by Vector.
2652         (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread): Include new m_xssInfo field in safety check.
2653         (WebCore):
2654         (WebCore::CompactHTMLToken::xssInfo): Added.
2655         (WebCore::CompactHTMLToken::setXSSInfo): Added.
2656         * html/parser/CompactHTMLToken.h: Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
2657         (WebCore):
2658         (CompactHTMLToken):
2659         (WTF): Add VectorTraits necessary for copying Vector fields objects that contain an OwnPtr.
2660         * html/parser/HTMLDocumentParser.cpp:
2661         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser): Add new didBlockScript() call.
2662         (WebCore::HTMLDocumentParser::pumpTokenizer):
2663         * html/parser/XSSAuditor.cpp: Renaming.
2664         (WebCore::XSSAuditor::filterToken):
2665         * html/parser/XSSAuditor.h: Renaming.
2666         (WebCore):
2667         (XSSAuditor):
2668         * html/parser/XSSAuditorDelegate.cpp:
2669         (WebCore::XSSInfo::isSafeToSendToAnotherThread):
2670         (WebCore):
2671         (WebCore::XSSAuditorDelegate::didBlockScript):
2672         * html/parser/XSSAuditorDelegate.h:
2673         (WebCore::XSSInfo::create):
2674         (XSSInfo):
2675         (WebCore::XSSInfo::XSSInfo):
2676         (XSSAuditorDelegate):
2677         * platform/KURL.cpp:
2678         (WebCore::KURL::isSafeToSendToAnotherThread): Added.
2679         (WebCore):
2680         * platform/KURL.h:
2681         (KURL):
2682         * platform/KURLGoogle.cpp:
2683         (WebCore):
2684         (WebCore::KURLGooglePrivate::isSafeToSendToAnotherThread): Added.
2685         * platform/KURLGooglePrivate.h:
2686         (KURLGooglePrivate):
2687         * platform/KURLWTFURLImpl.h:
2688         (WebCore::KURLWTFURLImpl::isSafeToSendToAnotherThread): Added.
2689
2690 2013-02-06  Dean Jackson  <dino@apple.com>
2691
2692         Minor updates to captions menu UI
2693         https://bugs.webkit.org/show_bug.cgi?id=109005
2694
2695         Reviewed by Eric Carlson.
2696
2697         Now that we only have a single section in the captions menu, remove the
2698         unnecessary wrapper element. Also update the UI for Mac so that the menu
2699         grows in size dynamically, and change the text we display for a caption
2700         that has neither label or language identifiers.
2701
2702         Covered by existing tests.
2703
2704         * English.lproj/Localizable.strings: New string for an unknown caption label.
2705         * css/fullscreenQuickTime.css: New rules for the captions menu.
2706         (video:-webkit-full-screen::-webkit-media-controls-closed-captions-container):
2707         (video:-webkit-full-screen::-webkit-media-controls-closed-captions-track-list):
2708         * css/mediaControlsQuickTime.css: Ditto.
2709         (video::-webkit-media-controls-closed-captions-container):
2710         (video::-webkit-media-controls-closed-captions-track-list):
2711         * html/shadow/MediaControlElements.cpp:
2712         (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu):
2713             Remove the <section> element container.
2714         * platform/LocalizedStrings.cpp:
2715         (WebCore::textTrackNoLabelText): New string for an unknown caption label.
2716
2717 2013-02-06  Vsevolod Vlasov  <vsevik@chromium.org>
2718
2719         Web Inspector: Remove isSnippet field from FileDescriptor and UISourceCode.
2720         https://bugs.webkit.org/show_bug.cgi?id=109045
2721         
2722         Reviewed by Pavel Feldman.
2723
2724         Snippets are now distinguished based on uiSourceCode project.
2725
2726         * inspector/front-end/JavaScriptSourceFrame.js:
2727         (WebInspector.JavaScriptSourceFrame.prototype._supportsEnabledBreakpointsWhileEditing):
2728         * inspector/front-end/NavigatorView.js:
2729         * inspector/front-end/ScriptSnippetModel.js:
2730         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
2731         * inspector/front-end/ScriptsNavigator.js:
2732         (WebInspector.ScriptsNavigator.prototype._navigatorViewForUISourceCode):
2733         (WebInspector.ScriptsNavigator.prototype.addUISourceCode):
2734         (WebInspector.ScriptsNavigator.prototype.removeUISourceCode):
2735         (WebInspector.ScriptsNavigator.prototype.revealUISourceCode):
2736         (WebInspector.ScriptsNavigator.prototype.rename):
2737         (WebInspector.SnippetsNavigatorView.prototype._handleEvaluateSnippet):
2738         (WebInspector.SnippetsNavigatorView.prototype._handleRemoveSnippet):
2739         * inspector/front-end/ScriptsPanel.js:
2740         (WebInspector.ScriptsPanel.prototype._showFile):
2741         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
2742         (WebInspector.ScriptsPanel.prototype.set _fileRenamed):
2743         * inspector/front-end/SimpleWorkspaceProvider.js:
2744         (WebInspector.SimpleWorkspaceProvider.prototype.addFile):
2745         (WebInspector.SimpleWorkspaceProvider.prototype.addFileForURL):
2746         * inspector/front-end/Workspace.js:
2747         (WebInspector.FileDescriptor):
2748         (WebInspector.Project.prototype._fileAdded):
2749
2750 2013-02-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2751
2752         Unreviewed, rolling out r141983.
2753         http://trac.webkit.org/changeset/141983
2754         https://bugs.webkit.org/show_bug.cgi?id=109055
2755
2756         lots of new crashes in handlescope (Requested by gavinp on
2757         #webkit).
2758
2759         * bindings/v8/DOMDataStore.h:
2760         (WebCore::DOMDataStore::setWrapperInObject):
2761         * bindings/v8/DOMWrapperWorld.h:
2762         (DOMWrapperWorld):
2763         (WebCore::DOMWrapperWorld::isolated):
2764         * bindings/v8/V8Binding.h:
2765         (WebCore):
2766         (WebCore::worldForEnteredContextIfIsolated):
2767         * bindings/v8/V8DOMWindowShell.cpp:
2768         (WebCore::V8DOMWindowShell::initializeIfNeeded):
2769         * bindings/v8/V8GCController.cpp:
2770         (WebCore::WrapperVisitor::WrapperVisitor):
2771         (WebCore):
2772         (WebCore::gcTree):
2773         (WebCore::V8GCController::didCreateWrapperForNode):
2774         (WebCore::V8GCController::gcPrologue):
2775         (WebCore::V8GCController::minorGCPrologue):
2776         (WebCore::V8GCController::majorGCPrologue):
2777         * bindings/v8/V8GCController.h:
2778         (V8GCController):
2779
2780 2013-02-06  Andreas Kling  <akling@apple.com>
2781
2782         Optimize GlyphPage for case where all glyphs are available in the same font.
2783         <http://webkit.org/b/108835>
2784         <rdar://problem/13157042>
2785
2786         Reviewed by Antti Koivisto.
2787
2788         Let GlyphPage begin optimistically assuming that all its glyphs will be represented in
2789         the same SimpleFontData*. In this (very common) case, only keep a single SimpleFontData*.
2790
2791         If glyphs from multiple fonts are mixed in one page, an array of per-glyph SimpleFontData*
2792         is allocated transparently.
2793
2794         4.98 MB progression on Membuster3.
2795
2796         * platform/graphics/GlyphPageTreeNode.cpp:
2797         (WebCore::GlyphPageTreeNode::initializePage):
2798         * platform/graphics/GlyphPage.h:
2799         (WebCore::GlyphPage::createUninitialized):
2800         (WebCore::GlyphPage::createZeroedSystemFallbackPage):
2801         (WebCore::GlyphPage::createCopiedSystemFallbackPage):
2802
2803             There are now three ways of constructing a GlyphPage, two of them are only used for
2804             creating system fallback pages.
2805
2806         (WebCore::GlyphPage::setGlyphDataForIndex):
2807
2808             Hold off creating a SimpleFontData* array until we're sure there are two different
2809             SimpleFontData* backing the glyphs in this page.
2810             We don't store font data for glyph #0, instead we let the getters always return null for it.
2811
2812         (WebCore::GlyphPage::~GlyphPage):
2813
2814             Free the SimpleFontData* array if needed.
2815
2816         (WebCore::GlyphPage::glyphDataForCharacter):
2817         (WebCore::GlyphPage::glyphDataForIndex):
2818         (WebCore::GlyphPage::fontDataForCharacter):
2819
2820             The font data for glyph #0 is always a null pointer now.
2821
2822         (WebCore::GlyphPage::clearForFontData):
2823
2824             Updated for new storage format.
2825
2826         * rendering/svg/SVGTextRunRenderingContext.cpp:
2827         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
2828
2829             Fix bug where non-zero glyph was temporarily associated with null font data,
2830             which triggered the new assertion in setGlyphDataForIndex().
2831
2832 2013-02-06  Pavel Feldman  <pfeldman@chromium.org>
2833
2834         Follow up to r141979: do not consume Home/End.
2835         Not reviewed.
2836
2837         * inspector/front-end/FilteredItemSelectionDialog.js:
2838         (WebInspector.FilteredItemSelectionDialog.prototype._onKeyDown):
2839
2840 2013-02-06  Vsevolod Vlasov  <vsevik@chromium.org>
2841
2842         Web Inspector: Remove show script folders setting
2843         https://bugs.webkit.org/show_bug.cgi?id=108940
2844
2845         Reviewed by Pavel Feldman.
2846
2847         Removed showScriptFolders setting, the sources are never shown as a flat list in navigator anymore.
2848
2849         * inspector/front-end/NavigatorView.js:
2850         (WebInspector.NavigatorView):
2851         (WebInspector.NavigatorView.prototype._getOrCreateFolderTreeElement):
2852         * inspector/front-end/Settings.js:
2853         * inspector/front-end/SettingsScreen.js:
2854         (WebInspector.GenericSettingsTab):
2855
2856 2013-02-06  Andrey Lushnikov  <lushnikov@chromium.org>
2857
2858         Web Inspector: update javascriptsourcetokenizer to produce "whitespaces" token
2859         https://bugs.webkit.org/show_bug.cgi?id=108945
2860
2861         Reviewed by Pavel Feldman.
2862
2863         Update re2c grammar for SourceJavaScriptTokenizer to produce
2864         "whitespace" token which holds consequtive whitespaces in it.
2865
2866         Updated existing tests expectations.
2867
2868         * inspector/front-end/DOMSyntaxHighlighter.js:
2869         (WebInspector.DOMSyntaxHighlighter.prototype.createSpan): Do not strip spaces from tokens with class "whitespaces".
2870         * inspector/front-end/SourceJavaScriptTokenizer.js: Regenerated.
2871         (WebInspector.SourceJavaScriptTokenizer.prototype.nextToken):
2872         * inspector/front-end/SourceJavaScriptTokenizer.re2js:
2873
2874 2013-02-06  Andrey Lushnikov  <lushnikov@chromium.org>
2875
2876         Web Inspector: refactor registerShortcuts method of DTE
2877         https://bugs.webkit.org/show_bug.cgi?id=109031
2878
2879         Reviewed by Pavel Feldman.
2880
2881         Implement _registerShortcuts method in TextEditorMainPanel which will
2882         bind its private methods to the different key combinations. Refactor
2883         method handlers handleUndoRedo, handleTabKeyPress and handleEnterKey
2884         from public to private.
2885
2886         No new tests: no change in behaviour.
2887
2888         * inspector/front-end/DefaultTextEditor.js:
2889         (WebInspector.DefaultTextEditor.prototype._registerShortcuts): Remove bindings of TextEditorMainPanel methods
2890         (WebInspector.DefaultTextEditor.prototype._handleKeyDown):
2891         (WebInspector.TextEditorMainPanel):
2892         (WebInspector.TextEditorMainPanel.prototype._registerShortcuts): Added.
2893         (WebInspector.TextEditorMainPanel.prototype._handleUndoRedo):
2894         (WebInspector.TextEditorMainPanel.prototype.handleKeyDown):
2895
2896 2013-02-06  Mike West  <mkwst@chromium.org>
2897
2898         Add an ENABLE_NOSNIFF feature flag.
2899         https://bugs.webkit.org/show_bug.cgi?id=109029
2900
2901         Reviewed by Jochen Eisinger.
2902
2903         This new flag will control the behavior of 'X-Content-Type-Options: nosniff'
2904         when processing script and other resource types.
2905
2906         * Configurations/FeatureDefines.xcconfig:
2907
2908 2013-02-06  Tommy Widenflycht  <tommyw@google.com>
2909
2910         MediaStream API: Implement DTMF support in RTCPeerConnection
2911         https://bugs.webkit.org/show_bug.cgi?id=106782
2912
2913         Reviewed by Adam Barth.
2914
2915         The WebRTC specification have added support for DTMF:
2916         http://dev.w3.org/2011/webrtc/editor/webrtc.html#peer-to-peer-dtmf
2917
2918         Implementation wise this is implemented using the same pattern as RTCDataChannel;
2919         where a RTCDTMFSenderHandler is created by the UA through a new method on
2920         RTCPeerConnectionHandler.
2921
2922         Test: fast/mediastream/RTCPeerConnection-dtmf.html
2923
2924         * CMakeLists.txt:
2925         * GNUmakefile.list.am:
2926         * Modules/mediastream/RTCDTMFSender.cpp: Added.
2927         (WebCore):
2928         (WebCore::RTCDTMFSender::create):
2929         (WebCore::RTCDTMFSender::RTCDTMFSender):
2930         (WebCore::RTCDTMFSender::~RTCDTMFSender):
2931         (WebCore::RTCDTMFSender::canInsertDTMF):
2932         (WebCore::RTCDTMFSender::track):
2933         (WebCore::RTCDTMFSender::toneBuffer):
2934         (WebCore::RTCDTMFSender::insertDTMF):
2935         (WebCore::RTCDTMFSender::didPlayTone):
2936         (WebCore::RTCDTMFSender::interfaceName):
2937         (WebCore::RTCDTMFSender::scriptExecutionContext):
2938         (WebCore::RTCDTMFSender::stop):
2939         (WebCore::RTCDTMFSender::eventTargetData):
2940         (WebCore::RTCDTMFSender::ensureEventTargetData):
2941         (WebCore::RTCDTMFSender::scheduleDispatchEvent):
2942         (WebCore::RTCDTMFSender::scheduledEventTimerFired):
2943         * Modules/mediastream/RTCDTMFSender.h: Added.
2944         (WebCore):
2945         (RTCDTMFSender):
2946         (WebCore::RTCDTMFSender::duration):
2947         (WebCore::RTCDTMFSender::interToneGap):
2948         * Modules/mediastream/RTCDTMFSender.idl: Added.
2949         * Modules/mediastream/RTCDTMFToneChangeEvent.cpp: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
2950         (WebCore):
2951         (WebCore::RTCDTMFToneChangeEvent::create):
2952         (WebCore::RTCDTMFToneChangeEvent::RTCDTMFToneChangeEvent):
2953         (WebCore::RTCDTMFToneChangeEvent::~RTCDTMFToneChangeEvent):
2954         (WebCore::RTCDTMFToneChangeEvent::tone):
2955         (WebCore::RTCDTMFToneChangeEvent::interfaceName):
2956         * Modules/mediastream/RTCDTMFToneChangeEvent.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
2957         (WebCore):
2958         (RTCDTMFToneChangeEventInit):
2959         (RTCDTMFToneChangeEvent):
2960         * Modules/mediastream/RTCDTMFToneChangeEvent.idl: Added.
2961         * Modules/mediastream/RTCPeerConnection.cpp:
2962         (WebCore::RTCPeerConnection::createDataChannel):
2963         (WebCore):
2964         (WebCore::RTCPeerConnection::getStreamByTrackId):
2965         (WebCore::RTCPeerConnection::createDTMFSender):
2966         * Modules/mediastream/RTCPeerConnection.h:
2967         (WebCore):
2968         (RTCPeerConnection):
2969         * Modules/mediastream/RTCPeerConnection.idl:
2970         * WebCore.gypi:
2971         * dom/EventNames.h:
2972         (WebCore):
2973         * dom/EventNames.in:
2974         * dom/EventTargetFactory.in:
2975         * platform/chromium/support/WebMediaStreamTrack.cpp:
2976         (WebKit::WebMediaStreamTrack::WebMediaStreamTrack):
2977         (WebKit):
2978         * platform/mediastream/RTCDTMFSenderHandler.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
2979         (WebCore):
2980         (RTCDTMFSenderHandler):
2981         (WebCore::RTCDTMFSenderHandler::~RTCDTMFSenderHandler):
2982         * platform/mediastream/RTCDTMFSenderHandlerClient.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
2983         (WebCore):
2984         (RTCDTMFSenderHandlerClient):
2985         (WebCore::RTCDTMFSenderHandlerClient::~RTCDTMFSenderHandlerClient):
2986         * platform/mediastream/RTCPeerConnectionHandler.h:
2987         (WebCore):
2988         (RTCPeerConnectionHandler):
2989         * platform/mediastream/chromium/RTCDTMFSenderHandlerChromium.cpp: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
2990         (WebCore):
2991         (WebCore::RTCDTMFSenderHandlerChromium::create):
2992         (WebCore::RTCDTMFSenderHandlerChromium::RTCDTMFSenderHandlerChromium):
2993         (WebCore::RTCDTMFSenderHandlerChromium::~RTCDTMFSenderHandlerChromium):
2994         (WebCore::RTCDTMFSenderHandlerChromium::setClient):
2995         (WebCore::RTCDTMFSenderHandlerChromium::currentToneBuffer):
2996         (WebCore::RTCDTMFSenderHandlerChromium::canInsertDTMF):
2997         (WebCore::RTCDTMFSenderHandlerChromium::insertDTMF):
2998         (WebCore::RTCDTMFSenderHandlerChromium::didPlayTone):
2999         * platform/mediastream/chromium/RTCDTMFSenderHandlerChromium.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
3000         (WebCore):
3001         (RTCDTMFSenderHandlerChromium):
3002         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
3003         (WebCore::RTCPeerConnectionHandlerChromium::createDTMFSender):
3004         (WebCore):
3005         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
3006         (RTCPeerConnectionHandlerChromium):
3007
3008 2013-02-04  Kentaro Hara  <haraken@chromium.org>
3009
3010         [V8] Remove V8GCController::m_edenNodes and make minor DOM GC more precise
3011         https://bugs.webkit.org/show_bug.cgi?id=108579
3012
3013         Reviewed by Adam Barth.
3014
3015         Currently V8GCController::m_edenNodes stores a list of nodes whose
3016         wrappers have been created since the latest GC. The reason why we
3017         needed m_edenNodes is that there was no way to know a list of wrappers
3018         in the new space of V8. By using m_edenNodes, we had been approximating
3019         'wrappers in the new space' by 'wrappers that have been created since
3020         the latest GC'.
3021
3022         Now V8 provides VisitHandlesForPartialDependence(), with which WebKit
3023         can know a list of wrappers in the new space. By using the API, we can
3024         remove V8GCController::m_edenNodes. The benefit is that (1) we no longer
3025         need to keep m_edenNodes and that (2) it enables more precise minor
3026         DOM GC (Remember that m_edenNodes was just an approximation).
3027
3028         Performance benchmark: https://bugs.webkit.org/attachment.cgi?id=185940
3029         The benchmark runs 300 iterations, each of which creates 100000 elements.
3030         The benchmark measures average, min, median, max and stdev of execution times
3031         of the 300 iterations. This will tell us the worst-case overhead of this change.
3032
3033         Before:
3034           mean=59.91ms, min=39ms, median=42ms, max=258ms, stdev=47.48ms
3035
3036         After:
3037           mean=58.75ms, min=35ms, median=41ms, max=250ms, stdev=47.32ms
3038
3039         As shown above, I couldn't observe any performance regression.
3040
3041         No tests. No change in behavior.
3042
3043         * bindings/v8/DOMDataStore.h:
3044         (WebCore::DOMDataStore::setWrapperInObject):
3045         * bindings/v8/DOMWrapperWorld.h:
3046         (DOMWrapperWorld):
3047         (WebCore::DOMWrapperWorld::getWorldWithoutContextCheck):
3048         * bindings/v8/V8Binding.h:
3049         (WebCore):
3050         (WebCore::worldForEnteredContextIfIsolated):
3051         (WebCore::worldForEnteredContextWithoutContextCheck):
3052         * bindings/v8/V8DOMWindowShell.cpp:
3053         (WebCore::V8DOMWindowShell::initializeIfNeeded):
3054         * bindings/v8/V8GCController.cpp:
3055         (WebCore::gcTree):
3056         (WebCore):
3057         (MinorGCWrapperVisitor):
3058         (WebCore::MinorGCWrapperVisitor::MinorGCWrapperVisitor):
3059         (WebCore::MinorGCWrapperVisitor::notifyFinished):
3060         (WebCore::MajorGCWrapperVisitor::MajorGCWrapperVisitor):
3061         (WebCore::V8GCController::gcPrologue):
3062         (WebCore::V8GCController::minorGCPrologue):
3063         (WebCore::V8GCController::majorGCPrologue):
3064         * bindings/v8/V8GCController.h:
3065         (V8GCController):
3066
3067 2013-02-06  Mihai Maerean  <mmaerean@adobe.com>
3068
3069         [CSSRegions] Assertion failure in Node::detach (!renderer || renderer->inRenderFlowThread())
3070         https://bugs.webkit.org/show_bug.cgi?id=104517
3071
3072         Reviewed by Julien Chaffraix.
3073
3074         The RenderObject::inRenderFlowThread bit could have become disconnected from the fact that the RenderObject
3075         has (or not) an enclosing RenderFlowThread.
3076         The cause of this was that, when setting or removing the parent of a RenderObject, the inRenderFlowThread flags
3077         wasn't being set/reset for the children too.
3078         This is now fixed by calling the new setInRenderFlowThreadIncludingDescendants.
3079
3080         The ASSERT was hit for anonymous blocks when detaching the document.
3081
3082         Test: fast/regions/detaching-regions-with-anonymous-blocks.html
3083
3084         * rendering/RenderObject.cpp:
3085         (WebCore::RenderObject::setInRenderFlowThreadRecursive):
3086         (WebCore):
3087         * rendering/RenderObject.h:
3088         (WebCore::RenderObject::setParent):
3089         (RenderObject):
3090
3091 2013-02-06  Marja Hölttä  <marja@chromium.org>
3092
3093         Take referrer policy into account when clearing the referrer header
3094         https://bugs.webkit.org/show_bug.cgi?id=86000
3095
3096         Reviewed by Alexey Proskuryakov.
3097
3098         The referrer should only be cleared when doing a https -> http redirect,
3099         if the policy is "default". Otherwise the referrer should be left intact.
3100
3101         In order to do that, added a function for checking the policy in
3102         NetworkingContext, and stored the NetworkingContext in ResourceHandle
3103         (like some ports already did).
3104
3105         No new tests (unskipped old tests).
3106
3107         * loader/FrameNetworkingContext.h:
3108         (WebCore::FrameNetworkingContext::shouldClearReferrerOnHTTPSToHTTPRedirect):
3109         (FrameNetworkingContext):
3110         * platform/network/BlobResourceHandle.cpp:
3111         (WebCore::BlobResourceHandle::BlobResourceHandle):
3112         * platform/network/NetworkingContext.h:
3113         (NetworkingContext):
3114         * platform/network/ResourceHandle.cpp:
3115         (WebCore::ResourceHandle::ResourceHandle):
3116         (WebCore::ResourceHandle::create):
3117         (WebCore::ResourceHandle::context):
3118         (WebCore):
3119         * platform/network/ResourceHandle.h:
3120         (ResourceHandle):
3121         * platform/network/ResourceHandleInternal.h:
3122         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
3123         (ResourceHandleInternal):
3124         * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
3125         (WebCore::ResourceHandle::start):
3126         (WebCore::ResourceHandle::loadResourceSynchronously):
3127         * platform/network/cf/ResourceHandleCFNet.cpp:
3128         (WebCore::willSendRequest):
3129         (WebCore::ResourceHandle::start):
3130         (WebCore::ResourceHandle::loadResourceSynchronously):
3131         * platform/network/chromium/ResourceHandle.cpp:
3132         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
3133         (WebCore::ResourceHandle::ResourceHandle):
3134         (WebCore::ResourceHandle::create):
3135         (WebCore::ResourceHandle::context):
3136         (WebCore):
3137         (WebCore::ResourceHandle::start):
3138         * platform/network/chromium/ResourceHandleInternal.h:
3139         (WebCore):
3140         (ResourceHandleInternal):
3141         (WebCore::ResourceHandleInternal::context):
3142         * platform/network/curl/ResourceHandleCurl.cpp:
3143         (WebCore::ResourceHandle::start):
3144         (WebCore::ResourceHandle::loadResourceSynchronously):
3145         * platform/network/mac/ResourceHandleMac.mm:
3146         (WebCore::ResourceHandle::start):
3147         (WebCore::ResourceHandle::loadResourceSynchronously):
3148         (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]):
3149         * platform/network/qt/QNetworkReplyHandler.cpp:
3150         (WebCore::QNetworkReplyHandler::redirect):
3151         * platform/network/qt/ResourceHandleQt.cpp:
3152         (WebCore::ResourceHandle::start):
3153         (WebCore::ResourceHandle::loadResourceSynchronously):
3154         * platform/network/soup/ResourceHandleSoup.cpp:
3155         (WebCore::doRedirect):
3156         (WebCore::ResourceHandle::start):
3157         * platform/network/win/ResourceHandleWin.cpp:
3158         (WebCore::ResourceHandle::start):
3159         (WebCore::ResourceHandle::loadResourceSynchronously):
3160
3161 2013-02-06  Pavel Feldman  <pfeldman@chromium.org>
3162
3163         Web Inspector: file selector list jumps as I type or move Up/Down
3164         https://bugs.webkit.org/show_bug.cgi?id=108933
3165
3166         Reviewed by Vsevolod Vlasov.
3167
3168         Missing return was scheduling extra updates.
3169
3170         * inspector/front-end/FilteredItemSelectionDialog.js:
3171         (WebInspector.FilteredItemSelectionDialog):
3172         (WebInspector.FilteredItemSelectionDialog.prototype._filterItems):
3173         (WebInspector.FilteredItemSelectionDialog.prototype._onKeyDown):
3174         (WebInspector.FilteredItemSelectionDialog.prototype._updateSelection):
3175
3176 2013-02-06  Kentaro Hara  <haraken@chromium.org>
3177
3178         [V8] Pass an Isolate to remaining GetTemplate()s
3179         https://bugs.webkit.org/show_bug.cgi?id=109001
3180
3181         Reviewed by Adam Barth.
3182
3183         No tests. No change in behavior.
3184
3185         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3186         (WebCore::V8DOMWindow::namedSecurityCheck): Because this method is a callback from V8,
3187         we cannot change its signature to receive an Isolate.
3188         (WebCore::V8DOMWindow::indexedSecurityCheck): Ditto.
3189
3190         * bindings/scripts/CodeGeneratorV8.pm:
3191         (GenerateHeader):
3192         (GenerateToV8Converters):
3193         * bindings/scripts/test/V8/V8Float64Array.cpp:
3194         (WebCore::V8Float64Array::createWrapper):
3195         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
3196         (WebCore::V8TestActiveDOMObject::createWrapper):
3197         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
3198         (WebCore::V8TestCustomNamedGetter::createWrapper):
3199         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
3200         (WebCore::V8TestEventConstructor::createWrapper):
3201         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3202         (WebCore::V8TestEventTarget::createWrapper):
3203         * bindings/scripts/test/V8/V8TestException.cpp:
3204         (WebCore::V8TestException::createWrapper):
3205         * bindings/scripts/test/V8/V8TestInterface.cpp:
3206         (WebCore::V8TestInterface::createWrapper):
3207         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
3208         (WebCore::V8TestMediaQueryListListener::createWrapper):
3209         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
3210         (WebCore::V8TestNamedConstructor::createWrapper):
3211         * bindings/scripts/test/V8/V8TestNode.cpp:
3212         (WebCore::V8TestNode::createWrapper):
3213         * bindings/scripts/test/V8/V8TestObj.cpp:
3214         (WebCore::V8TestObj::createWrapper):
3215         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
3216         (WebCore::V8TestOverloadedConstructors::createWrapper):
3217         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3218         (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
3219         * bindings/v8/V8DOMWrapper.cpp:
3220         (WebCore::V8DOMWrapper::createWrapper):
3221         * bindings/v8/V8DOMWrapper.h:
3222         (V8DOMWrapper):
3223         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
3224         (WebCore::V8HTMLDocument::wrapInShadowObject):
3225
3226 2013-02-06  Sheriff Bot  <webkit.review.bot@gmail.com>
3227
3228         Unreviewed, rolling out r141961.
3229         http://trac.webkit.org/changeset/141961
3230         https://bugs.webkit.org/show_bug.cgi?id=109019
3231
3232         assertion failures on svn tests such as fonts-glyph-04-t.svg
3233         (Requested by falken on #webkit).
3234
3235         * platform/graphics/GlyphPage.h:
3236         (WebCore::GlyphPage::create):
3237         (WebCore::GlyphPage::glyphDataForCharacter):
3238         (WebCore::GlyphPage::glyphDataForIndex):
3239         (WebCore::GlyphPage::fontDataForCharacter):
3240         (WebCore::GlyphPage::setGlyphDataForIndex):
3241         (GlyphPage):
3242         (WebCore::GlyphPage::copyFrom):
3243         (WebCore::GlyphPage::clear):
3244         (WebCore::GlyphPage::clearForFontData):
3245         (WebCore::GlyphPage::GlyphPage):
3246         * platform/graphics/GlyphPageTreeNode.cpp:
3247         (WebCore::GlyphPageTreeNode::initializePage):
3248
3249 2013-02-05  Sheriff Bot  <webkit.review.bot@gmail.com>
3250
3251         Unreviewed, rolling out r141964.
3252         http://trac.webkit.org/changeset/141964
3253         https://bugs.webkit.org/show_bug.cgi?id=109014
3254
3255         caused performance regression (Requested by hayato on
3256         #webkit).
3257
3258         * CMakeLists.txt:
3259         * GNUmakefile.list.am:
3260         * Target.pri:
3261         * WebCore.gypi:
3262         * WebCore.xcodeproj/project.pbxproj:
3263         * css/CSSAllInOne.cpp:
3264         * css/DocumentRuleSets.cpp: Removed.
3265         * css/DocumentRuleSets.h: Removed.
3266         * css/StyleResolver.cpp:
3267         (WebCore::StyleResolver::StyleResolver):
3268         (WebCore::StyleResolver::collectRulesFromUserStyleSheets):
3269         (WebCore):
3270         (WebCore::makeRuleSet):
3271         (WebCore::StyleResolver::resetAuthorStyle):
3272         (WebCore::StyleResolver::appendAuthorStyleSheets):
3273         (WebCore::StyleResolver::matchAuthorRules):
3274         (WebCore::StyleResolver::matchUserRules):
3275         (WebCore::StyleResolver::classNamesAffectedByRules):
3276         (WebCore::StyleResolver::locateCousinList):
3277         (WebCore::StyleResolver::canShareStyleWithElement):
3278         (WebCore::StyleResolver::locateSharedStyle):
3279         (WebCore::StyleResolver::styleForElement):
3280         (WebCore::StyleResolver::styleForPage):
3281         (WebCore::StyleResolver::checkRegionStyle):
3282         (WebCore::StyleResolver::applyProperty):
3283         (WebCore::StyleResolver::collectFeatures):
3284         (WebCore::StyleResolver::reportMemoryUsage):
3285         * css/StyleResolver.h:
3286         (StyleResolver):
3287         (WebCore::StyleResolver::usesSiblingRules):
3288         (WebCore::StyleResolver::usesFirstLineRules):
3289         (WebCore::StyleResolver::usesBeforeAfterRules):
3290         (WebCore::StyleResolver::hasSelectorForAttribute):
3291         (WebCore::StyleResolver::hasSelectorForClass):
3292         (WebCore::StyleResolver::hasSelectorForId):
3293         * dom/DocumentStyleSheetCollection.cpp:
3294         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
3295
3296 2013-02-05  Kentaro Hara  <haraken@chromium.org>
3297
3298         Add #if USE(V8) to Node::V8CollectableDuringMinorGCFlag
3299         https://bugs.webkit.org/show_bug.cgi?id=109009
3300
3301         Reviewed by Kent Tamura.
3302
3303         Node flags should be saved. V8CollectableDuringMinorGCFlag is used by V8 only.
3304
3305         * dom/Node.h:
3306         (Node):
3307
3308 2013-02-05  Vsevolod Vlasov  <vsevik@chromium.org>
3309
3310         Web Inspector: Add ending slashes automatically to file mappings.
3311         https://bugs.webkit.org/show_bug.cgi?id=108936
3312
3313         Reviewed by Pavel Feldman.
3314
3315         * inspector/front-end/SettingsScreen.js:
3316         (WebInspector.WorkspaceSettingsTab.prototype._addFileMappingClicked):
3317
3318 2013-02-05  Eric Carlson  <eric.carlson@apple.com>
3319
3320         More updates to Caption user preferences
3321         https://bugs.webkit.org/show_bug.cgi?id=108997
3322
3323         Reviewed by Dean Jackson.
3324
3325         * html/HTMLMediaElement.cpp:
3326         (WebCore::HTMLMediaElement::captionPreferencesChanged): Give the media controls a chance
3327             to update for a preferences change.
3328         * html/shadow/MediaControlElements.cpp:
3329         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Add optional "force update" 
3330             param to force font size recalc even when the video size hasn't changed.
3331         * html/shadow/MediaControlElements.h:
3332
3333         * html/shadow/MediaControls.cpp:
3334         (WebCore::MediaControls::textTrackPreferencesChanged): New, force a font size recalc.
3335         * html/shadow/MediaControls.h:
3336
3337         * html/track/TextTrackCueGeneric.cpp:
3338         (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties): Don't set width/size of cues
3339             that use default positioning. Use "start" as the default alignment.
3340
3341         * page/CaptionUserPreferencesMac.mm:
3342         (WebCore::CaptionUserPreferencesMac::captionsWindowCSS): Set padding when the window is visible
3343             so it shows around the cue background.
3344         (WebCore::CaptionUserPreferencesMac::captionsBackgroundCSS): Set padding to 0 when the background
3345             is visible.
3346         (WebCore::CaptionUserPreferencesMac::windowRoundedCornerRadiusCSS): Add "px" to the border radius
3347             so it actually works.
3348         * rendering/RenderTextTrackCue.cpp:
3349         (WebCore::RenderTextTrackCue::layout): Special case generic cues with default style.
3350         (WebCore::RenderTextTrackCue::repositionGenericCue):
3351         * rendering/RenderTextTrackCue.h:
3352
3353 2013-02-05  Hayato Ito  <hayato@chromium.org>
3354
3355         Split each RuleSet and feature out from StyleResolver into its own class.
3356         https://bugs.webkit.org/show_bug.cgi?id=107777
3357
3358         Reviewed by Dimitri Glazkov.
3359
3360         Splitting each RuleSet and feature out from StyleResover into its onw class, DocumentRuleSets,
3361         to manage them separately.
3362
3363         This is one of the attempts to try to resolve meta bug (bug 89879)
3364         to lose StyleResolver's weight.  We need further action to factor
3365         StyleResolver to separate it into some classes cleanly.
3366         See also https://bugs.webkit.org/show_bug.cgi?id=108890. A following patch will address that.
3367
3368         No tests. No change in behavior.
3369
3370         * CMakeLists.txt:
3371         * GNUmakefile.list.am:
3372         * Target.pri:
3373         * WebCore.gypi:
3374         * WebCore.xcodeproj/project.pbxproj:
3375         * css/CSSAllInOne.cpp:
3376         * css/DocumentRuleSets.cpp: Added.
3377         (WebCore):
3378         (WebCore::DocumentRuleSets::DocumentRuleSets):
3379         (WebCore::DocumentRuleSets::~DocumentRuleSets):
3380         (WebCore::DocumentRuleSets::initUserStyle): New helper to initialize each RuleSets.
3381         (WebCore::DocumentRuleSets::collectRulesFromUserStyleSheets): Factored out from StyleResolver.
3382         (WebCore::makeRuleSet): Ditto.
3383         (WebCore::DocumentRuleSets::resetAuthorStyle): Ditto.
3384         (WebCore::DocumentRuleSets::appendAuthorStyleSheets): Ditto.
3385         (WebCore::DocumentRuleSets::collectFeatures): Ditto.
3386         (WebCore::DocumentRuleSets::reportMemoryUsage): New methods to report memory usage. Factored out from StyleResolver.
3387         * css/DocumentRuleSets.h: Added.
3388         (WebCore):
3389         (DocumentRuleSets):
3390         (WebCore::DocumentRuleSets::authorStyle): Moved from StyleResolver.
3391         (WebCore::DocumentRuleSets::userStyle): Ditto.
3392         (WebCore::DocumentRuleSets::features): Ditto.
3393         (WebCore::DocumentRuleSets::sibling): Ditto.
3394         (WebCore::DocumentRuleSets::uncommonAttribute): Ditto.
3395         * css/StyleResolver.cpp:
3396         (WebCore::StyleResolver::StyleResolver):
3397         (WebCore::StyleResolver::appendAuthorStyleSheets): Now calls DocumentRuleSets::appendAuthorStyleSheets.
3398         (WebCore::StyleResolver::matchAuthorRules): Use m_ruleSets.
3399         (WebCore::StyleResolver::matchUserRules): Ditto.
3400         (WebCore::StyleResolver::classNamesAffectedByRules): Ditto.
3401         (WebCore::StyleResolver::locateCousinList): Ditto.
3402         (WebCore::StyleResolver::canShareStyleWithElement): Ditto.
3403         (WebCore::StyleResolver::locateSharedStyle): Ditto.
3404         (WebCore::StyleResolver::styleForPage): Ditto.
3405         (WebCore::StyleResolver::checkRegionStyle): Ditto.
3406         (WebCore::StyleResolver::applyProperty): Ditto.
3407         (WebCore::StyleResolver::reportMemoryUsage): Now calls DocumentRuleSets::reportMemoryUsage.
3408         * css/StyleResolver.h:
3409         (WebCore::StyleResolver::scopeResolver):
3410         (StyleResolver):
3411         (WebCore::StyleResolver::ruleSets): accessor r to DocumentRuleSets.
3412         (WebCore::StyleResolver::usesSiblingRules): Use m_ruleSets.
3413         (WebCore::StyleResolver::usesFirstLineRules): Ditto.
3414         (WebCore::StyleResolver::usesBeforeAfterRules): Ditto.
3415         (WebCore::StyleResolver::hasSelectorForAttribute): Ditto.
3416         (WebCore::StyleResolver::hasSelectorForClass): Ditto.
3417         (WebCore::StyleResolver::hasSelectorForId): Ditto.
3418         * dom/DocumentStyleSheetCollection.cpp:
3419         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
3420
3421 2013-02-05  Julien Chaffraix  <jchaffraix@webkit.org>
3422
3423         [CSS Grid Layout] Grid item's logical height is not properly recomputed after -webkit-grid-column / -webkit-grid-row changes
3424         https://bugs.webkit.org/show_bug.cgi?id=108975
3425
3426         Reviewed by Tony Chang.
3427
3428         Test: fast/css-grid-layout/implicit-position-dynamic-change.html
3429
3430         * rendering/RenderBox.cpp:
3431         (WebCore::RenderBox::clearContainingBlockOverrideSize):
3432         (WebCore::RenderBox::clearOverrideContainingBlockContentLogicalHeight):
3433         * rendering/RenderBox.h:
3434         Added clearOverrideContainingBlockContentLogicalHeight and updated clearContainingBlockOverrideSize
3435         to use it.
3436
3437         * rendering/RenderGrid.cpp:
3438         (WebCore::RenderGrid::minContentForChild):
3439         (WebCore::RenderGrid::maxContentForChild):
3440         Added missing clearContainingBlockOverrideSize to ensure we don't use a previous layout's override.
3441
3442 2013-02-05  Andreas Kling  <akling@apple.com>
3443
3444         Optimize GlyphPage for case where all glyphs are available in the same font.
3445         <http://webkit.org/b/108835>
3446         <rdar://problem/13157042>
3447
3448         Reviewed by Antti Koivisto.
3449
3450         Let GlyphPage begin optimistically assuming that all its glyphs will be represented in
3451         the same SimpleFontData*. In this (very common) case, only keep a single SimpleFontData*.
3452
3453         If glyphs from multiple fonts are mixed in one page, an array of per-glyph SimpleFontData*
3454         is allocated transparently.
3455
3456         4.98 MB progression on Membuster3.
3457
3458         * platform/graphics/GlyphPageTreeNode.cpp:
3459         (WebCore::GlyphPageTreeNode::initializePage):
3460         * platform/graphics/GlyphPage.h:
3461         (WebCore::GlyphPage::createUninitialized):
3462         (WebCore::GlyphPage::createZeroedSystemFallbackPage):
3463         (WebCore::GlyphPage::createCopiedSystemFallbackPage):
3464
3465             There are now three ways of constructing a GlyphPage, two of them are only used for
3466             creating system fallback pages.
3467
3468         (WebCore::GlyphPage::setGlyphDataForIndex):
3469
3470             Hold off creating a SimpleFontData* array until we're sure there are two different
3471             SimpleFontData* backing the glyphs in this page.
3472             We don't store font data for glyph #0, instead we let the getters always return null for it.
3473
3474         (WebCore::GlyphPage::~GlyphPage):
3475
3476             Free the SimpleFontData* array if needed.
3477
3478         (WebCore::GlyphPage::glyphDataForCharacter):
3479         (WebCore::GlyphPage::glyphDataForIndex):
3480         (WebCore::GlyphPage::fontDataForCharacter):
3481
3482             The font data for glyph #0 is always a null pointer now.
3483
3484         (WebCore::GlyphPage::clearForFontData):
3485
3486             Updated for new storage format.
3487
3488 2013-02-05  Kent Tamura  <tkent@chromium.org>
3489
3490         INPUT_MULTIPLE_FIELDS_UI: Read-only inputs should be focusable
3491         https://bugs.webkit.org/show_bug.cgi?id=108795
3492
3493         Reviewed by Kentaro Hara.
3494
3495         According to the standard [1], readonly form controls should be focusable.
3496
3497         - Sub-fields should be focusable if they are read-only. We should check
3498           isDisabled mainly.
3499         - All keyboard operations should not be handled if a field is disabled,
3500           and focus navigation keyboard operations should be handled even if a
3501           field is read-only.
3502
3503         [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#the-readonly-attribute
3504
3505         No new tests. Update
3506         fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html
3507         for the new behavior.
3508
3509         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
3510         (WebCore::BaseMultipleFieldsDateAndTimeInputType::isKeyboardFocusable):
3511         Make <input> focusable even if it is read-only.
3512         * html/shadow/DateTimeEditElement.cpp:
3513         (WebCore::DateTimeEditElement::isFieldOwnerDisabled):
3514         Separate isFieldOwnerDisabledOrReadOnly into two.
3515         (WebCore::DateTimeEditElement::isFieldOwnerReadOnly): Ditto.
3516         (WebCore::DateTimeEditElement::updateUIState):
3517         We don't need to focus out if this is read-only.
3518         * html/shadow/DateTimeEditElement.h:
3519         (DateTimeEditElement): Separate isFieldOwnerDisabledOrReadOnly into two.
3520         * html/shadow/DateTimeFieldElement.cpp:
3521         (WebCore::DateTimeFieldElement::defaultEventHandler):
3522         Skip handleKeyboardEvent if the field is disabled or the owner input is
3523         disabled or read-only. handleKeyboardEvent handles editing key
3524         operations.
3525         (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler):
3526         If this field is disabled or the owner input is disabled, all keyboard
3527         inputs are ignored.
3528         If this field is read-only, we handle only left and right arrows to
3529         change focus, and skip down/up/backspace/del keys.
3530         (WebCore::DateTimeFieldElement::isFieldOwnerDisabled):
3531         A helper function to check disable state of the owner input.
3532         (WebCore::DateTimeFieldElement::isFieldOwnerReadOnly):
3533         A helper function to check read-only state of the owner input.
3534         (WebCore::DateTimeFieldElement::isFocusable):
3535         This field should be focusable if it is read-only and not disabled.
3536         * html/shadow/DateTimeFieldElement.h:
3537         (FieldOwner): Separate isFieldOwnerDisabledOrReadOnly into two.
3538         (DateTimeFieldElement):
3539         Declare isFieldOwnerDisabled and isFieldOwnerReadOnly.
3540         * html/shadow/DateTimeNumericFieldElement.cpp:
3541         (WebCore::DateTimeNumericFieldElement::handleKeyboardEvent):
3542         Remove redundant isDisabled check. It is done in
3543         DateTimeFieldElement::defaultEventHandler.
3544
3545 2013-02-05  Eric Carlson  <eric.carlson@apple.com>
3546
3547         [Mac] Complete plumbing so captions menu can indicate track type
3548         https://bugs.webkit.org/show_bug.cgi?id=108994
3549
3550         Reviewed by Dean Jackson.
3551
3552         Plumb "isClosedCaptions" through to the Mac media engine.
3553
3554         Updated media/video-controls-captions-trackmenu-localized.html and results.
3555
3556         * html/track/InbandTextTrack.cpp:
3557         (WebCore::InbandTextTrack::isClosedCaptions): New, pass the call through to the private track.
3558         * html/track/InbandTextTrack.h:
3559         (InbandTextTrack):
3560         * html/track/TextTrack.cpp:
3561         (WebCore::TextTrack::TextTrack): Lose the member variable, this won't be accessed often enough
3562             to make it worth caching the value.
3563         * html/track/TextTrack.h:
3564         (WebCore::TextTrack::isClosedCaptions): Make virtual so derived classes can oveerride.
3565         * platform/graphics/InbandTextTrackPrivate.h:
3566         (WebCore::InbandTextTrackPrivate::isClosedCaptions): New.
3567         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
3568         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
3569         (WebCore::InbandTextTrackPrivateAVFObjC::isClosedCaptions): New.
3570
3571 2013-02-05  Mark Lam  <mark.lam@apple.com>
3572
3573         Change DatabaseTask and DatabaseThread to work with DatabaseBackendAsync
3574         instead of Database.
3575         https://bugs.webkit.org/show_bug.cgi?id=108995.
3576
3577         Reviewed by Sam Weinig.
3578
3579         This change also moves the task inner classes from Database to
3580         DatabaseBackendAsync.
3581
3582         No new tests.
3583
3584         * Modules/webdatabase/Database.cpp:
3585         (WebCore::Database::from):
3586         * Modules/webdatabase/Database.h:
3587         (Database):
3588         * Modules/webdatabase/DatabaseBackend.h:
3589         (DatabaseBackend):
3590         * Modules/webdatabase/DatabaseBackendAsync.h:
3591         (DatabaseBackendAsync):
3592         * Modules/webdatabase/DatabaseTask.cpp:
3593         (WebCore::DatabaseTask::DatabaseTask):
3594         (WebCore::DatabaseBackendAsync::DatabaseOpenTask::DatabaseOpenTask):
3595         (WebCore::DatabaseBackendAsync::DatabaseOpenTask::doPerformTask):
3596         (WebCore::DatabaseBackendAsync::DatabaseOpenTask::debugTaskName):
3597         (WebCore::DatabaseBackendAsync::DatabaseCloseTask::DatabaseCloseTask):
3598         (WebCore::DatabaseBackendAsync::DatabaseCloseTask::doPerformTask):
3599         (WebCore::DatabaseBackendAsync::DatabaseCloseTask::debugTaskName):
3600         (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::DatabaseTransactionTask):
3601         (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::doPerformTask):
3602         (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::debugTaskName):
3603         (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::DatabaseTableNamesTask):
3604         (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::doPerformTask):
3605         (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::debugTaskName):
3606         * Modules/webdatabase/DatabaseTask.h:
3607         (WebCore::DatabaseTask::database):
3608         (DatabaseTask):
3609         (WebCore::DatabaseBackendAsync::DatabaseOpenTask::create):
3610         (DatabaseBackendAsync::DatabaseOpenTask):
3611         (WebCore::DatabaseBackendAsync::DatabaseCloseTask::create):
3612         (DatabaseBackendAsync::DatabaseCloseTask):
3613         (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::create):
3614         (DatabaseBackendAsync::DatabaseTableNamesTask):
3615         * Modules/webdatabase/DatabaseThread.cpp:
3616         (WebCore::DatabaseThread::databaseThread):
3617         (WebCore::DatabaseThread::recordDatabaseOpen):
3618         (WebCore::DatabaseThread::recordDatabaseClosed):
3619         (WebCore::SameDatabasePredicate::SameDatabasePredicate):
3620         (SameDatabasePredicate):
3621         (WebCore::DatabaseThread::unscheduleDatabaseTasks):
3622         * Modules/webdatabase/DatabaseThread.h:
3623         (DatabaseThread):
3624
3625 2013-02-05  Mark Lam  <mark.lam@apple.com>
3626
3627         Rename ENUM_CLASS_BEGIN() macro to ENUM_CLASS(), and make DatabaseType a strong enum.
3628         https://bugs.webkit.org/show_bug.cgi?id=108988.
3629
3630         Reviewed by Alexey Proskuryakov.
3631
3632         No new tests.
3633
3634         * Modules/webdatabase/DatabaseBackend.cpp:
3635         (WebCore::DatabaseBackend::DatabaseBackend):
3636         * Modules/webdatabase/DatabaseBackend.h:
3637         (DatabaseBackend):
3638         * Modules/webdatabase/DatabaseBackendAsync.cpp:
3639         (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
3640         * Modules/webdatabase/DatabaseBackendSync.cpp:
3641         (WebCore::DatabaseBackendSync::DatabaseBackendSync):
3642         * Modules/webdatabase/DatabaseBasicTypes.h:
3643         (WebCore::ENUM_CLASS):
3644         * Modules/webdatabase/DatabaseError.h:
3645         (WebCore::ENUM_CLASS):
3646
3647 2013-02-05  Kentaro Hara  <haraken@chromium.org>
3648
3649         [V8] Remove deprecatedV8String() and deprecatedV8Integer()
3650         https://bugs.webkit.org/show_bug.cgi?id=108919
3651
3652         Reviewed by Adam Barth.
3653
3654         No tests. No change in behavior.
3655
3656         * bindings/v8/V8Binding.cpp:
3657         (WebCore::toXPathNSResolver):
3658         * bindings/v8/V8Binding.h:
3659         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
3660         (WebCore::V8CustomXPathNSResolver::create):
3661         (WebCore::V8CustomXPathNSResolver::V8CustomXPathNSResolver):
3662         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
3663         * bindings/v8/custom/V8CustomXPathNSResolver.h:
3664         (V8CustomXPathNSResolver):
3665
3666 2013-02-05   Vineet Chaudhary  <rgf748@motorola.com>
3667
3668         formenctype to have empty string as default value.
3669         https://bugs.webkit.org/show_bug.cgi?id=108969
3670
3671         Reviewed by Kent Tamura.
3672
3673         The spec says formEnctype should only have an invalid value default, not a missing value default.
3674         Spec: http://www.w3.org/html/wg/drafts/html/master/forms.html#attr-fs-formenctype
3675               http://www.whatwg.org/specs/web-apps/current-work/#attr-fs-formenctype
3676
3677         No new tests. Covered by existing test case fast/forms/submit-form-attributes.html
3678
3679         * html/HTMLFormControlElement.cpp: For the missing formEnctype attr return empty string.
3680         (WebCore::HTMLFormControlElement::formEnctype):
3681
3682 2013-02-04  Kentaro Hara  <haraken@chromium.org>
3683
3684         [V8] Reduce usage of deprecatedString() and deprecatedInteger()
3685         https://bugs.webkit.org/show_bug.cgi?id=108909
3686
3687         Reviewed by Adam Barth.
3688
3689         By passing an Isolate parameter around, we can reduce usage of
3690         deprecated methods.
3691
3692         No tests. No change in behavior.
3693
3694         * bindings/scripts/CodeGeneratorV8.pm:
3695         (GenerateNormalAttrSetter):
3696         (GenerateEventListenerCallback):
3697         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3698         (WebCore::TestEventTargetV8Internal::addEventListenerCallback):
3699         (WebCore::TestEventTargetV8Internal::removeEventListenerCallback):
3700         * bindings/scripts/test/V8/V8TestObj.cpp:
3701         (WebCore::TestObjV8Internal::addEventListenerCallback):
3702         (WebCore::TestObjV8Internal::removeEventListenerCallback):
3703         * bindings/v8/IDBBindingUtilities.cpp:
3704         (WebCore::get):
3705         (WebCore::set):
3706         (WebCore::getNthValueOnKeyPath):
3707         (WebCore::canInjectNthValueOnKeyPath):
3708         (WebCore::ensureNthValueOnKeyPath):
3709         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
3710         (WebCore::injectIDBKeyIntoScriptValue):
3711         (WebCore::canInjectIDBKeyIntoScriptValue):
3712         * bindings/v8/NPV8Object.cpp:
3713         (WebCore::createValueListFromVariantArgs):
3714         (_NPN_Invoke):
3715         (_NPN_InvokeDefault):
3716         (_NPN_SetProperty):
3717         (_NPN_Construct):
3718         * bindings/v8/ScriptController.cpp:
3719         (WebCore::ScriptController::compileAndRunScript):
3720         * bindings/v8/ScriptProfiler.cpp:
3721         (WebCore):
3722         (WebCore::ScriptProfiler::takeHeapSnapshot):
3723         * bindings/v8/ScriptSourceCode.cpp:
3724         (WebCore::ScriptSourceCode::compileScript):
3725         * bindings/v8/ScriptSourceCode.h:
3726         (ScriptSourceCode):
3727         * bindings/v8/V8LazyEventListener.cpp:
3728         (WebCore::V8LazyEventListener::prepareListenerObject):
3729         * bindings/v8/V8NPObject.cpp:
3730         (WebCore::npObjectInvokeImpl):
3731         (WebCore::npObjectGetProperty):
3732         * bindings/v8/V8NPUtils.cpp:
3733         (WebCore::convertNPVariantToV8Object):
3734         * bindings/v8/V8NPUtils.h:
3735         (WebCore):
3736         * bindings/v8/V8Utilities.cpp:
3737         (WebCore::createHiddenDependency):
3738         (WebCore::removeHiddenDependency):
3739         (WebCore::transferHiddenDependency):
3740         * bindings/v8/V8Utilities.h:
3741         (WebCore):
3742         * bindings/v8/WorkerScriptController.cpp:
3743         (WebCore::WorkerScriptController::evaluate):
3744         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3745         (WebCore::V8DOMWindow::addEventListenerCallback):
3746         (WebCore::V8DOMWindow::removeEventListenerCallback):
3747
3748 2013-02-05  Kentaro Hara  <haraken@chromium.org>
3749
3750         [V8] Make an Isolate parameter mandatory in HasInstance()
3751         https://bugs.webkit.org/show_bug.cgi?id=108917
3752
3753         Reviewed by Adam Barth.
3754
3755         No tests. No change in behavior.
3756
3757         * bindings/scripts/CodeGeneratorV8.pm:
3758         (GenerateHeader):
3759         (GenerateImplementation):
3760         * bindings/scripts/test/V8/V8Float64Array.cpp:
3761         (WebCore::V8Float64Array::HasInstance):
3762         * bindings/scripts/test/V8/V8Float64Array.h:
3763         (V8Float64Array):
3764         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
3765         (WebCore::V8TestActiveDOMObject::HasInstance):
3766         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
3767         (V8TestActiveDOMObject):
3768         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
3769         (WebCore::V8TestCustomNamedGetter::HasInstance):
3770         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
3771         (V8TestCustomNamedGetter):
3772         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
3773         (WebCore::V8TestEventConstructor::HasInstance):
3774         * bindings/scripts/test/V8/V8TestEventConstructor.h:
3775         (V8TestEventConstructor):
3776         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3777         (WebCore::V8TestEventTarget::HasInstance):
3778         * bindings/scripts/test/V8/V8TestEventTarget.h:
3779         (V8TestEventTarget):
3780         * bindings/scripts/test/V8/V8TestException.cpp:
3781         (WebCore::V8TestException::HasInstance):
3782         * bindings/scripts/test/V8/V8TestException.h:
3783         (V8TestException):
3784         * bindings/scripts/test/V8/V8TestInterface.cpp:
3785         (WebCore::V8TestInterface::HasInstance):
3786         * bindings/scripts/test/V8/V8TestInterface.h:
3787         (V8TestInterface):
3788         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
3789         (WebCore::V8TestMediaQueryListListener::HasInstance):
3790         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
3791         (V8TestMediaQueryListListener):
3792         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
3793         (WebCore::V8TestNamedConstructor::HasInstance):
3794         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
3795         (V8TestNamedConstructor):
3796         * bindings/scripts/test/V8/V8TestNode.cpp:
3797         (WebCore::V8TestNode::HasInstance):
3798         * bindings/scripts/test/V8/V8TestNode.h:
3799         (V8TestNode):
3800         * bindings/scripts/test/V8/V8TestObj.cpp:
3801         (WebCore::V8TestObj::HasInstance):
3802         * bindings/scripts/test/V8/V8TestObj.h:
3803         (V8TestObj):
3804         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
3805         (WebCore::V8TestOverloadedConstructors::HasInstance):
3806         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
3807         (V8TestOverloadedConstructors):
3808         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3809         (WebCore::V8TestSerializedScriptValueInterface::HasInstance):
3810         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
3811         (V8TestSerializedScriptValueInterface):
3812         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
3813         (WebCore::toWebGLUniformLocation):
3814
3815 2013-02-05  Kentaro Hara  <haraken@chromium.org>
3816
3817         [JSC] Clean up CodeGeneratorJS.pm by introducing HasCustom{Getter,Setter,Method}
3818         https://bugs.webkit.org/show_bug.cgi?id=108898
3819
3820         Reviewed by Sam Weinig.
3821
3822         No tests. No change in behavior.
3823
3824         * bindings/scripts/CodeGeneratorJS.pm:
3825         (GenerateHeader):
3826         (GenerateImplementation):
3827         (HasCustomGetter):
3828         (HasCustomSetter):
3829         (HasCustomMethod):
3830
3831 2013-02-05  Dana Jansens  <danakj@chromium.org>
3832
3833         [chromium] Provide compositor offscreen context through the WebLayerTreeViewClient interface
3834         https://bugs.webkit.org/show_bug.cgi?id=107776
3835
3836         Reviewed by James Robinson.
3837
3838         Allow the compositor thread's context to be retrieved on either thread,
3839         so the main thread can create and pass the context to the impl thread
3840         via its own mechanisms.
3841
3842         Move the code to bind the GrGLInterface to a WebGraphicsContext3D into
3843         chromium's GraphicsContext3DPrivate. The chromium-side code will need
3844         to implement this code itself.
3845
3846         * platform/chromium/support/GraphicsContext3DPrivate.cpp:
3847         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
3848         (WebCore):
3849         (WebCore::GraphicsContext3DPrivate::grContext):
3850         * platform/chromium/support/GraphicsContext3DPrivate.h:
3851         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
3852         (WebCore::SharedGraphicsContext3D::getForImplThread):
3853
3854 2013-02-05  Tony Gentilcore  <tonyg@chromium.org>
3855
3856         Continue making XSSAuditor thread safe: Remove dependency on the parser's tokenizer
3857         https://bugs.webkit.org/show_bug.cgi?id=108666
3858
3859         Reviewed by Adam Barth.
3860
3861         This is the final dependency on the parser, so we remove that as well. Yay!
3862
3863         No new tests because no new functionality.
3864
3865         * html/parser/HTMLDocumentParser.cpp:
3866         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3867         (WebCore::HTMLDocumentParser::pumpTokenizer): Pass m_tokenizer->shouldAllowCDATA()
3868         * html/parser/XSSAuditor.cpp:
3869         (WebCore::XSSAuditor::XSSAuditor): Remove isMainThread() check because we have one in init() anyway.
3870         Move m_isEnabled and m_documentURL initialization to init() because we have a Document* there.
3871         (WebCore::XSSAuditor::init):
3872         (WebCore::XSSAuditor::filterToken):
3873         (WebCore::XSSAuditor::filterStartToken):
3874         (WebCore::XSSAuditor::filterEndToken):
3875         (WebCore::XSSAuditor::filterScriptToken):
3876         (WebCore::XSSAuditor::decodedSnippetForJavaScript):
3877         * html/parser/XSSAuditor.h:
3878         (WebCore::FilterTokenRequest::FilterTokenRequest):
3879         (FilterTokenRequest):
3880         (XSSAuditor):
3881
3882 2013-02-05  Enrica Casucci  <enrica@apple.com>
3883
3884         Make baseWritingDirectionForSelectionStart available to all platforms in the Editor class.
3885         https://bugs.webkit.org/show_bug.cgi?id=108977.
3886
3887         Reviewed by Ryosuke Niwa.
3888         
3889         Now that baseWritingDirectionForSelectionStart doesn't use
3890         platform specific type anymore, we can make it available for
3891         all platforms. This way it can be used for iOS as well.
3892
3893         No new tests, no functionality change.
3894
3895         * editing/Editor.cpp:
3896         (WebCore::Editor::baseWritingDirectionForSelectionStart): Added.
3897         * editing/Editor.h: Moved from PLATFORM(MAC).
3898         * editing/mac/EditorMac.mm: baseWritingDirectionForSelectionStart removed.
3899
3900 2013-02-05  Benjamin Poulain  <bpoulain@apple.com>
3901
3902         Avoid String->AtomicString conversion in Attr::childrenChanged()
3903         https://bugs.webkit.org/show_bug.cgi?id=108742
3904
3905         Reviewed by Andreas Kling.
3906
3907         * dom/Attr.cpp:
3908         (WebCore::Attr::childrenChanged): StringBuilder can output AtomicString directly.
3909
3910 2013-02-05  Yusuf Ozuysal  <yusufo@google.com>
3911
3912         [chromium] Enable shouldGesturesTriggerActive for Android
3913         https://bugs.webkit.org/show_bug.cgi?id=96948
3914
3915         Reviewed by James Robinson.
3916
3917         We need this to fix performance issues we are getting because of touchstart 
3918         triggering hover/active states.
3919
3920         No new tests. The tests introduced in https://bugs.webkit.org/show_bug.cgi?id=96060
3921         should run with the corrected behavior and would cover this change as well.
3922
3923         * page/EventHandler.cpp:
3924         (WebCore::shouldGesturesTriggerActive):
3925
3926 2013-02-05  Mark Lam  <mark.lam@apple.com>
3927
3928         Introduced back-end database classes + a few small fixes.
3929         https://bugs.webkit.org/show_bug.cgi?id=108759.
3930
3931         Reviewed by Brady Eidson.
3932
3933         1. Added DatabaseBackendContext, DatabaseBackendAsync, and DatabaseBackendSync.
3934            These are backends for DatabaseContext, Database, and DatabaseSync
3935            respectively.
3936         2. Added DatabaseBase to hold common code between Database and DatabaseSync.
3937         3. Renamed a few functions.
3938         4. Cleaned up unneeded code in ~DatabaseSync().
3939         5. Added some FIXMEs as reminders or places to clean up when we're done
3940            refactoring.
3941         6. Moved the calling of ScriptController::initializeThreading() from the Database
3942            constructor to DatabaseManager::openDatabase(). This just moves the call
3943            earlier in the same code path. System initialization work (i.e. initializing
3944            script threading in this case) should be done by the manager instead of by
3945            each Database instance.
3946
3947         No new tests.
3948
3949         * CMakeLists.txt:
3950         * GNUmakefile.list.am:
3951         * Modules/webdatabase/AbstractDatabaseServer.h:
3952         (AbstractDatabaseServer):
3953         * Modules/webdatabase/Database.cpp:
3954         (WebCore::Database::Database):
3955         (WebCore::Database::backend):
3956         * Modules/webdatabase/Database.h:
3957         (Database):
3958         * Modules/webdatabase/DatabaseBackend.cpp:
3959         (WebCore::DatabaseBackend::DatabaseBackend):
3960         (WebCore::DatabaseBackend::~DatabaseBackend):
3961         (WebCore::DatabaseBackend::incrementalVacuumIfNeeded):
3962         * Modules/webdatabase/DatabaseBackend.h:
3963         (DatabaseBackend):
3964         (WebCore::DatabaseBackend::databaseContext):
3965         (WebCore::DatabaseBackend::setFrontend):
3966         * Modules/webdatabase/DatabaseBackendAsync.cpp: Added.
3967         (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
3968         * Modules/webdatabase/DatabaseBackendAsync.h: Added.
3969         (DatabaseBackendAsync):
3970         * Modules/webdatabase/DatabaseBackendContext.cpp: Added.
3971         (WebCore::DatabaseBackendContext::securityOrigin):
3972         (WebCore::DatabaseBackendContext::isContextThread):
3973         * Modules/webdatabase/DatabaseBackendContext.h: Added.
3974         (DatabaseBackendContext):
3975         (WebCore::DatabaseBackendContext::scriptExecutionContext):
3976         * Modules/webdatabase/DatabaseBackendSync.cpp: Added.
3977         (WebCore::DatabaseBackendSync::DatabaseBackendSync):
3978         (WebCore::DatabaseBackendSync::~DatabaseBackendSync):
3979         * Modules/webdatabase/DatabaseBackendSync.h: Added.
3980         (DatabaseBackendSync):
3981         * Modules/webdatabase/DatabaseBase.cpp: Added.
3982         (WebCore::DatabaseBase::DatabaseBase):
3983         (WebCore::DatabaseBase::scriptExecutionContext):
3984         (WebCore::DatabaseBase::logErrorMessage):
3985         * Modules/webdatabase/DatabaseBase.h: Added.
3986         (DatabaseBase):
3987         * Modules/webdatabase/DatabaseContext.cpp:
3988         (WebCore::DatabaseContext::DatabaseContext):
3989         (WebCore::DatabaseContext::backend):
3990         * Modules/webdatabase/DatabaseContext.h:
3991         (DatabaseContext):
3992         * Modules/webdatabase/DatabaseManager.cpp:
3993         (WebCore::DatabaseManager::openDatabase):
3994         (WebCore::DatabaseManager::openDatabaseSync):
3995         (WebCore::DatabaseManager::hasOpenDatabases):
3996         (WebCore::DatabaseManager::interruptAllDatabasesForContext):
3997         (WebCore::DatabaseManager::getMaxSizeForDatabase):
3998         (WebCore::DatabaseManager::logErrorMessage):
3999         * Modules/webdatabase/DatabaseManager.h:
4000         (DatabaseManager):
4001         * Modules/webdatabase/DatabaseServer.cpp:
4002         (WebCore::DatabaseServer::interruptAllDatabasesForContext):
4003         (WebCore::DatabaseServer::canEstablishDatabase):
4004         * Modules/webdatabase/DatabaseServer.h:
4005         * Modules/webdatabase/DatabaseSync.cpp:
4006         (WebCore::DatabaseSync::DatabaseSync):
4007         (WebCore::DatabaseSync::~DatabaseSync):
4008         (WebCore::DatabaseSync::backend):
4009         * Modules/webdatabase/DatabaseSync.h:
4010         (DatabaseSync):
4011         * Modules/webdatabase/DatabaseTracker.cpp:
4012         (WebCore::DatabaseTracker::openTrackerDatabase):
4013         (WebCore::DatabaseTracker::canEstablishDatabase):
4014         (WebCore::DatabaseTracker::hasEntryForDatabase):
4015         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
4016         (WebCore::DatabaseTracker::populateOriginsIfNeeded):
4017         (WebCore::DatabaseTracker::databaseNamesForOriginNoLock):
4018         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
4019         (WebCore::DatabaseTracker::setDatabaseDetails):
4020         (WebCore::DatabaseTracker::usageForOriginNoLock):
4021         (WebCore::DatabaseTracker::setQuota):
4022         (WebCore::DatabaseTracker::addDatabase):
4023         (WebCore::DatabaseTracker::deleteOrigin):
4024         (WebCore::DatabaseTracker::isDeletingDatabaseOrOriginFor):
4025         (Web