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