Web Inspector: highlight occurences of word in DefaultTextEditor
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-01-25  Andrey Lushnikov  <lushnikov@chromium.org>
2
3         Web Inspector: highlight occurences of word in DefaultTextEditor
4         https://bugs.webkit.org/show_bug.cgi?id=105523
5
6         Reviewed by Pavel Feldman.
7
8         Highlight occurrences of selected word in DefaultTextEditor by the means of new highlight regex API.
9
10         Test: inspector/editor/text-editor-highlight-token.html
11
12         * inspector/front-end/DefaultTextEditor.js:
13         (WebInspector.TextEditorMainPanel):
14         (WebInspector.TextEditorMainPanel.prototype._handleSelectionChange):
15         (WebInspector.TextEditorMainPanel.TokenHighlighter): Added.
16         (WebInspector.TextEditorMainPanel.TokenHighlighter.prototype.handleSelectionChange):
17         (WebInspector.TextEditorMainPanel.TokenHighlighter.prototype._regexString):
18         (WebInspector.TextEditorMainPanel.TokenHighlighter.prototype._highlight):
19         (WebInspector.TextEditorMainPanel.TokenHighlighter.prototype._removeHighlight):
20         (WebInspector.TextEditorMainPanel.TokenHighlighter.prototype._isWord):
21         * inspector/front-end/textEditor.css:
22         (.text-editor-token-highlight):
23
24 2013-01-25  Alexander Paschenko  <alexander.pashenko@lge.com>
25
26         [TexMap] Flickering after transitions on Apple HTML5 demo
27         https://bugs.webkit.org/show_bug.cgi?id=102501
28
29         Reviewed by Noam Rosenthal.
30
31         The problem is caused by inconsistent state of TextureMapperLayer's transformation matrix
32         and opacity data during and after the end of animation.
33         This patch solves the problem by introducing three additional private flags
34         to TextureMapperLayer:
35         m_shouldUpdateCurrentTransformFromGraphicsLayer,
36         m_shouldUpdateCurrentOpacityFromGraphicsLayer, and
37         m_shouldUpdateCurrentFiltersFromGraphicsLayer.
38         The latter has been introduced in order to avoid similar future problems
39         with m_currentFilters.
40         On these flags' basis, TextureMapperLayer is able to decide whether to update
41         its inner state or not.
42         These flags themselves are set based on GraphicsLayerTextureMapper's changeMask
43         which indicates what details of the state have been changed since the last sync.
44
45         No new tests - this doesn't expose any testable surface.
46         Eyes-only check has been made to ensure that the problem is gone now.
47
48         * platform/graphics/texmap/TextureMapperLayer.cpp:
49         (WebCore::TextureMapperLayer::setAnimatedTransform):
50         sets m_shouldUpdateCurrentTransformFromGraphicsLayer to false and
51         updates m_currentTransform based on the updated state from GraphicsLayerAnimation.
52         (WebCore):
53         (WebCore::TextureMapperLayer::setAnimatedOpacity):
54         sets m_shouldUpdateCurrentOpacityFromGraphicsLayer to false and
55         updates m_currentOpacity based on the updated state from GraphicsLayerAnimation.
56         (WebCore::TextureMapperLayer::setAnimatedFilters):
57         sets m_shouldUpdateCurrentFiltersFromGraphicsLayer to false and
58         updates m_currentFilters based on the updated state from GraphicsLayerAnimation.
59         (WebCore::TextureMapperLayer::flushCompositingStateForThisLayerOnly):
60         sets m_shouldUpdateCurrent* flags based on GLTM's changeMask. Also illegal modification
61         of m_currentTransform that caused flickering has been removed from this method.
62         (WebCore::TextureMapperLayer::syncAnimations): updates m_currentTransform and/or
63         m_currentOpacity and/or m_currentFilters if corresponding flags allow to do so.
64         * platform/graphics/texmap/TextureMapperLayer.h:
65         (WebCore::TextureMapperLayer::TextureMapperLayer): aforementioned flags
66         get initialized in ctor.
67         (TextureMapperLayer): aforementioned flags are declared in the class.
68
69
70 2013-01-25  Marja Hölttä  <marja@chromium.org>
71
72         Refactor InspectorMemoryAgent: memory data as a map.
73
74         https://bugs.webkit.org/show_bug.cgi?id=107938
75
76         Reviewed by Yury Semikhatsky.
77
78         No new tests (no functional changes, only refactoring).
79
80         * inspector/InspectorController.cpp:
81         (WebCore::InspectorController::InspectorController):
82         (WebCore::InspectorController::getProcessMemoryDistribution):
83         (WebCore):
84         * inspector/InspectorController.h:
85         (WebCore):
86         (InspectorController):
87         * inspector/InspectorMemoryAgent.cpp:
88         (WebCore::addPlatformComponentsInfo):
89         (WebCore):
90         (WebCore::addMemoryInstrumentationDebugData):
91         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
92         (WebCore::InspectorMemoryAgent::reportMemoryUsage):
93         (WebCore::InspectorMemoryAgent::getProcessMemoryDistributionAsMap):
94         * inspector/InspectorMemoryAgent.h:
95         (InspectorMemoryAgent):
96
97 2013-01-25  Huang Dongsung  <luxtella@company100.net>
98
99         [Texmap] Refactor code related to debug border and repaint count.
100         https://bugs.webkit.org/show_bug.cgi?id=105787
101
102         Reviewed by Noam Rosenthal.
103
104         Currently, TextureMapperBackingStore, CoordinatedBackingStore and
105         GraphicsLayerTextureMapper have duplicated code to draw debug border or
106         repaint count. This patch refactors that all platform layers draw debug
107         border and repaint count in the consistent way:
108         TextureMapper::drawBorder() and TextureMapper::drawRepaintCounter().
109
110         There are three big changes:
111         1. TextureMapperLayer has the debug visuals like GraphicsLayer.
112         Both debug border and repaint count are called as the debug visuals.
113         2. We use the same color and width to Mac port because we get that info using
114         GraphicsLayer::updateDebugIndicators().
115         3. Draw borders for background color, backing store and contents layer,
116         while drawing repaint count only for backing store.
117
118         No new tests. This functionality is for debugging, so we cannot test using DRT.
119
120         * platform/graphics/cairo/GraphicsContext3DPrivate.h:
121         * platform/graphics/qt/GraphicsContext3DQt.cpp:
122         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
123         (WebCore::GraphicsLayerTextureMapper::setShowDebugBorder):
124         (WebCore):
125         (WebCore::GraphicsLayerTextureMapper::setShowRepaintCounter):
126         (WebCore::GraphicsLayerTextureMapper::flushCompositingStateForThisLayerOnly):
127         (WebCore::GraphicsLayerTextureMapper::updateDebugBorderAndRepaintCountIfNeeded):
128         (WebCore::GraphicsLayerTextureMapper::setDebugBorder):
129         (WebCore::GraphicsLayerTextureMapper::updateBackingStoreIfNeeded):
130         (WebCore::GraphicsLayerTextureMapper::prepareBackingStore):
131         (WebCore::GraphicsLayerTextureMapper::setRepaintCount):
132         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
133         (GraphicsLayerTextureMapper):
134         (WebCore::GraphicsLayerTextureMapper::debugBorderColor):
135         (WebCore::GraphicsLayerTextureMapper::debugBorderWidth):
136         * platform/graphics/texmap/TextureMapper.h:
137         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
138         (WebCore::TextureMapperTiledBackingStore::adjustedTransformForRect):
139         (WebCore):
140         (WebCore::TextureMapperTiledBackingStore::paintToTextureMapper):
141         (WebCore::TextureMapperTiledBackingStore::drawBorder):
142             Override TextureMapperPlatformLayer::drawBorder() to draw the border
143             for each tile.
144         (WebCore::TextureMapperTiledBackingStore::drawRepaintCounter):
145         * platform/graphics/texmap/TextureMapperBackingStore.h:
146         (WebCore::TextureMapperBackingStore::drawRepaintCounter):
147         (TextureMapperBackingStore):
148         (TextureMapperTiledBackingStore):
149         * platform/graphics/texmap/TextureMapperGL.cpp:
150         (WebCore::TextureMapperGL::drawRepaintCounter):
151         * platform/graphics/texmap/TextureMapperGL.h:
152         * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
153         (WebCore::TextureMapperImageBuffer::drawBorder):
154         (WebCore):
155         (WebCore::TextureMapperImageBuffer::drawRepaintCounter):
156         * platform/graphics/texmap/TextureMapperImageBuffer.h:
157         (TextureMapperImageBuffer):
158         * platform/graphics/texmap/TextureMapperLayer.cpp:
159         (WebCore::TextureMapperLayer::paintSelf):
160         (WebCore::TextureMapperLayer::flushCompositingStateForThisLayerOnly):
161         * platform/graphics/texmap/TextureMapperLayer.h:
162         (State):
163         (WebCore::TextureMapperLayer::State::State):
164         * platform/graphics/texmap/TextureMapperPlatformLayer.h:
165         (WebCore::TextureMapperPlatformLayer::drawBorder):
166
167 2013-01-24  Patrick Gansterer  <paroga@webkit.org>
168
169         Build fix for !ENABLE(DRAG_SUPPORT) after r140286.
170
171         * page/AutoscrollController.cpp:
172         (WebCore::AutoscrollController::autoscrollTimerFired):
173
174 2013-01-25  Ken Kania  <kkania@chromium.org>
175
176         Web Inspector: Move dispatchMouseEvent optional params after x,y
177         https://bugs.webkit.org/show_bug.cgi?id=107828
178
179         Reviewed by Pavel Feldman.
180
181         No new tests, as this just rearranges the order of arguments to make
182         JSCompiler happy. The params were rearranged in r140649 to match
183         dispatchKeyEvent's params.
184
185         * inspector/Inspector.json:
186         * inspector/InspectorInputAgent.cpp:
187         (WebCore::InspectorInputAgent::dispatchMouseEvent):
188         * inspector/InspectorInputAgent.h:
189         (InspectorInputAgent):
190
191 2013-01-25  Alexander Pavlov  <apavlov@chromium.org>
192
193         Web Inspector: [Styles] Editing a property value containing a trimmed data: URL breaks the style
194         https://bugs.webkit.org/show_bug.cgi?id=107936
195
196         Reviewed by Yury Semikhatsky.
197
198         Restore the original CSS property value before editing.
199
200         Test: inspector/styles/edit-value-with-trimmed-url.html
201
202         * inspector/front-end/StylesSidebarPane.js:
203
204 2013-01-25  Eugene Klyuchnikov  <eustas@chromium.org>
205
206         Web Inspector: [Network] Use DataGrid column alignment instead of custom styling.
207         https://bugs.webkit.org/show_bug.cgi?id=107935
208
209         Reviewed by Pavel Feldman.
210
211         On Network Panel column alignment is specified both in
212         column descriptors and in CSS stylesheet.
213
214         Only one alignment specifier should last.
215
216         * inspector/front-end/DataGrid.js:
217         (WebInspector.DataGridNode.prototype.createTD): Extracted common code.
218         (WebInspector.DataGridNode.prototype.createCell): Use "createTD". 
219         * inspector/front-end/NetworkPanel.js:
220         (WebInspector.NetworkDataGridNode.prototype._createDivInTD): Ditto.
221         * inspector/front-end/networkLogView.css: Remove exheberant rules.
222         * inspector/front-end/networkPanel.css: Fix whitespaces.
223
224 2013-01-25  Sergey Ryazanov  <serya@chromium.org>
225
226         Web Inspector: Add explanation for Console object expansion behaviour
227         https://bugs.webkit.org/show_bug.cgi?id=107793
228
229         Reviewed by Pavel Feldman.
230
231         * English.lproj/localizedStrings.js:
232         * inspector/front-end/ConsoleMessage.js:
233         (WebInspector.ConsoleMessageImpl.prototype._formatParameterAsArrayOrObject):
234         * inspector/front-end/inspector.css:
235         (.object-info-state-note):
236         (.object-info-state-note::before):
237         (.object-info-state-note:hover):
238         (.section.expanded .object-info-state-note):
239         (.section.expanded .properties, .event-bar.expanded .event-properties):
240         (.pane.expanded .properties, .event-bar .event-properties):
241
242 2013-01-25  Claudio Saavedra  <csaavedra@igalia.com>
243
244         Missing files in GNUmakefile.list.am for Notifications support
245         https://bugs.webkit.org/show_bug.cgi?id=107934
246
247         Reviewed by Philippe Normand.
248
249         * GNUmakefile.list.am: Add DOMWindowNotifications.idl and
250         WorkerContextNotifications.idl to dom_binding_idls and
251         JSNotificationCustom.{cpp,h} to webcore_sources, since without
252         this the Notifications will be broken.
253
254 2013-01-25  Andrey Lushnikov  <lushnikov@chromium.org>
255
256         Web Inspector: implement search for workspace sources
257         https://bugs.webkit.org/show_bug.cgi?id=107814
258
259         Reviewed by Pavel Feldman.
260
261         Implement generic WebInspector.ContentProvider.performSearchInContent method and use it in both
262         StaticContentProvider and fileSystemWorkspaceProvider.
263
264         No new tests.
265
266         * inspector/front-end/ContentProvider.js:
267         (WebInspector.ContentProvider.performSearchInContent): Added.
268         * inspector/front-end/ContentProviders.js:
269         (WebInspector.StaticContentProvider.prototype.):
270         (WebInspector.StaticContentProvider.prototype.searchInContent):
271         * inspector/front-end/FileSystemWorkspaceProvider.js:
272         (WebInspector.FileSystemWorkspaceProvider.prototype.contentCallback):
273         (WebInspector.FileSystemWorkspaceProvider.prototype.searchInFileContent):
274
275 2013-01-25  Elliott Sprehn  <esprehn@gmail.com>
276
277         Assert the connectedSubframeCount is consistent and fix over counting
278         https://bugs.webkit.org/show_bug.cgi?id=107302
279
280         Reviewed by Alexey Proskuryakov.
281
282         Add a debug assertion that walks the subtree during frame disconnection
283         and manually counts the number of connected subframes to assert that the
284         value from Node::connectedSubframeCount() is the same as if we traversed
285         through the tree.
286
287         In fixing the places where this assertion failed I made document destruction
288         faster by not walking the entire document looking for frames if the entire
289         frame tree has been destroyed by way of FrameLoader::detachChildren().
290         I had inadvertently introduced this improvement in r133933, but then I
291         regressed it in r140090 when we switched to counting because I didn't
292         realize we destroy the frame tree separate of frame disconnection on
293         document unload so all frames could have been destroyed but the counts
294         left on the ancestors.
295
296         I also fixed another overcounting case where the adoption agency algorithm
297         may call ContainerNode::takeAllChildrenFrom() which in turn calls
298         ContainerNode::removeAllChildren() and could have left a connected subframe
299         count on the node even though all the frames had been removed.
300
301         This assertion did not uncover any cases of undercounting the number of
302         frames.
303
304         This also fixes a rare edge case where removeChild of an iframe that
305         was already being unloaded would not unload the frame until the top level
306         unload was done, and a reparenting of the iframe would not cause it to load.
307
308         Test: fast/frames/reparent-in-unload-contentdocument.html
309
310         * dom/ContainerNode.cpp:
311         (WebCore::ContainerNode::removeAllChildren):
312         (WebCore::ContainerNode::parserInsertBefore):
313         (WebCore::ContainerNode::parserRemoveChild):
314         (WebCore::ContainerNode::parserAppendChild):
315         * dom/ContainerNodeAlgorithms.cpp:
316         (WebCore):
317         (WebCore::assertConnectedSubframeCountIsConsistent):
318         * dom/ContainerNodeAlgorithms.h:
319         (WebCore):
320         (WebCore::ChildFrameDisconnector::disconnect):
321         * dom/Node.cpp:
322         (WebCore::Node::updateAncestorConnectedSubframeCountForRemoval):
323         (WebCore):
324         (WebCore::Node::updateAncestorConnectedSubframeCountForInsertion):
325         * dom/Node.h:
326         (Node):
327         * html/HTMLFrameOwnerElement.cpp:
328         (WebCore::HTMLFrameOwnerElement::clearContentFrame):
329         (WebCore):
330         (WebCore::HTMLFrameOwnerElement::disconnectContentFrame):
331         * html/HTMLFrameOwnerElement.h:
332         (HTMLFrameOwnerElement):
333
334 2013-01-25  Pavel Feldman  <pfeldman@chromium.org>
335
336         Web Inspector: inspector slows down pages with many anonymous scripts.
337         https://bugs.webkit.org/show_bug.cgi?id=107928
338
339         Reviewed by Alexander Pavlov.
340
341         The problem was that workspace code introduced n^2 complexity for unique URI calculation.
342
343         * inspector/front-end/SimpleWorkspaceProvider.js:
344         (WebInspector.SimpleWorkspaceProvider):
345         (WebInspector.SimpleWorkspaceProvider.prototype.uniqueURI):
346
347 2013-01-25  Jussi Kukkonen  <jussi.kukkonen@intel.com>
348
349         [CMake][EFL] Build ThirdParty/leveldb when IndexedDB is enabled
350         https://bugs.webkit.org/show_bug.cgi?id=106443
351
352         Reviewed by Laszlo Gombos.
353
354         LevelDB is now included in ThirdParty. Use it when IndexDB is
355         enabled for EFL.
356
357         * CMakeLists.txt:
358         Build ThirdParty/leveldb when WTF_USE_LEVELDB is set
359
360 2013-01-25  Kent Tamura  <tkent@chromium.org>
361
362         INPUT_MULTIPLE_FIELDS_UI: Inconsistent value of aria-valuetext attribute
363         https://bugs.webkit.org/show_bug.cgi?id=107897
364
365         Reviewed by Kentaro Hara.
366
367         aria-valuetext and aria-valuenow attributes had inconsistent values in
368         a case of initial empty state and a case that a user clears a field.
369
370         - aria-valuetext attribute should have "blank" message in the initial
371           empty state.
372         - aria-valuenow attribute should be removed in the cleared empty state.
373
374         Also, we have a bug that aira-valuenow had a symbolic value such as "AM"
375         "January". It should always have a numeric value according to the
376         specification.
377         http://www.w3.org/TR/wai-aria/states_and_properties#aria-valuenow
378
379         No new tests. Updates fast/forms/*-multiple-fields/*-multiple-fields-ax-aria-attributes.html.
380
381         * html/shadow/DateTimeFieldElement.cpp:
382         (WebCore::DateTimeFieldElement::DateTimeFieldElement):
383         Set "blank" message to aria-valuetext attribute.
384         (WebCore::DateTimeFieldElement::updateVisibleValue):
385         aria-valuenow attribute should be a numeric value. Apply String::number
386         to the return value of valueForARIAValueNow.
387         Remove aria-valuenow attribute if nothing is selected.
388         (WebCore::DateTimeFieldElement::valueForARIAValueNow):
389         Added.
390         * html/shadow/DateTimeFieldElement.h:
391         (DateTimeFieldElement): Declare valueForARIAValueNow.
392
393         * html/shadow/DateTimeSymbolicFieldElement.cpp:
394         (WebCore::DateTimeSymbolicFieldElement::valueForARIAValueNow):
395         Added. Returns 1 + internal selection index.
396         For example, the function returns 1 for January.
397         * html/shadow/DateTimeSymbolicFieldElement.h:
398         (DateTimeSymbolicFieldElement): Declare valueForARIAValueNow.
399
400 2013-01-24  Hans Wennborg  <hans@chromium.org>
401
402         Disable Clang's -Wreturn-type-c-linkage for Source/WebCore/bindings/v8/
403         https://bugs.webkit.org/show_bug.cgi?id=107845
404
405         Reviewed by Adam Barth.
406
407         A recent version of Clang started warning about code in
408         Source/WebCore/bindings/v8/npruntime.cpp.
409
410         In this case it is warning about an 'extern "c"' function returning a
411         non-POD type. But because the function has internal linkage, the
412         warning doesn't really apply.
413
414         This change suppresses the warning in the meantime.
415
416         Tested by building with Clang r172454.
417
418         * WebCore.gyp/WebCore.gyp:
419
420 2013-01-25  Eberhard Graether  <egraether@google.com>
421
422         Web Inspector: add checkbox for continuous painting to the inspector's settings
423         https://bugs.webkit.org/show_bug.cgi?id=107352
424
425         Reviewed by Pavel Feldman.
426
427         This change adds a checkbox to activate continuous painting to the WebInspector's
428         rendering settings and plumbs the setting to Chromium's WebLayerTreeView. The
429         setting is visible if InspectorClient::canContinuouslyPaint() returns true.
430
431         No new tests.
432
433         * English.lproj/localizedStrings.js:
434         * inspector/Inspector.json:
435         * inspector/InspectorClient.h:
436         (WebCore::InspectorClient::canContinuouslyPaint):
437         (WebCore::InspectorClient::setContinuousPaintingEnabled):
438         (InspectorClient):
439         * inspector/InspectorPageAgent.cpp:
440         (PageAgentState):
441         (WebCore::InspectorPageAgent::restore):
442         (WebCore::InspectorPageAgent::disable):
443         (WebCore::InspectorPageAgent::canContinuouslyPaint):
444         (WebCore):
445         (WebCore::InspectorPageAgent::setContinuousPaintingEnabled):
446         * inspector/InspectorPageAgent.h:
447         * inspector/front-end/Settings.js:
448         * inspector/front-end/SettingsScreen.js:
449         (WebInspector.GenericSettingsTab):
450         (WebInspector.GenericSettingsTab.prototype.get _continuousPaintingChanged):
451         * inspector/front-end/inspector.js:
452         (WebInspector.doLoadedDone):
453
454 2013-01-25  Dominic Mazzoni  <dmazzoni@google.com>
455
456         REGRESSION (r140658): Multiple accessibility failures on GTK
457         https://bugs.webkit.org/show_bug.cgi?id=107832
458
459         Reviewed by Chris Fleizach.
460
461         In the ATK accessibility implementation, attachWrapper
462         might create a different object depending on the role of
463         the WebCore AccessibilityObject, whereas on other platforms
464         attachWrapper doesn't care. Calling init before attachWrapper
465         solves the problem.
466
467         Re-enables 7 skipped tests.
468
469         * accessibility/AXObjectCache.cpp:
470         (WebCore::AXObjectCache::getOrCreate):
471
472 2013-01-24  Kent Tamura  <tkent@chromium.org>
473
474         INPUT_MULTIPLE_FIELDS_UI: Refactoring: Remove confusing minimum() and maximum() of DateTimeSymbolicFieldElement
475         https://bugs.webkit.org/show_bug.cgi?id=107918
476
477         Reviewed by Kentaro Hara.
478
479         DateTimeSymbolicFieldElement::minimum() and maximum() are very
480         confusing. They don't return minimum/maximum value of 0-based symbol
481         index though valueAsInteger is 0-based. These functions are used only
482         for ARIA attributes in DateTimeFieldElement::initialize().
483
484         - Remove DateTimeFieldElement::minimum() and maximum(), and pass
485         minimum/maximum values for ARIA attributes as function arguments.
486         - DateTimeNumericFieldElement::maximum() is now non-virtual.
487           It is called by subclasses.
488
489         No new tests. This should not change any behavior.
490
491         * html/shadow/DateTimeFieldElement.cpp:
492         (WebCore::DateTimeFieldElement::initialize):
493         Add axMimimum/axMaximum arguments. Don't use minimum() and maximum().
494         * html/shadow/DateTimeFieldElement.h:
495         (DateTimeFieldElement): Ditto.
496         * html/shadow/DateTimeNumericFieldElement.cpp:
497         (WebCore::DateTimeNumericFieldElement::initialize):
498         Pass m_range.minimum and maximum to DateTimeFieldElement::initialize().
499         * html/shadow/DateTimeNumericFieldElement.h:
500         (DateTimeNumericFieldElement):
501         - Add initialize()
502         - Make maximum() non-virtual
503         - Remove minimum().
504         * html/shadow/DateTimeSymbolicFieldElement.cpp:
505         (WebCore::DateTimeSymbolicFieldElement::initialize):
506         Pass m_minimumIndex + 1 and m_maximumIndex + 1 to
507         DateTimeFieldElement::initialize().
508         * html/shadow/DateTimeSymbolicFieldElement.h:
509         (DateTimeSymbolicFieldElement):
510         Add initialize() and remove minimum() and maximum().
511
512 2013-01-24  Kent Tamura  <tkent@chromium.org>
513
514         INPUT_MULTIPLE_FIELDS_UI: Refactoring: Remove unused DateTimeHourFieldElement::valueAsInteger
515         https://bugs.webkit.org/show_bug.cgi?id=107915
516
517         Reviewed by Kentaro Hara.
518
519         DateTimeHourFieldElement::valueAsInteger is never called. Remove it and
520         make valueAsInteger non-public.
521
522         No new tests. This shouldn't change any behavior.
523
524         * html/shadow/DateTimeFieldElement.h:
525         (DateTimeFieldElement): Make valueAsInteger protected.
526         * html/shadow/DateTimeFieldElements.cpp:
527         Remove DateTimeHourFieldElement::valueAsInteger.
528         (WebCore::DateTimeHourFieldElement::populateDateTimeFieldsState):
529         Remove unnecessary DateTimeNumericFieldElement:: prefix.
530         * html/shadow/DateTimeFieldElements.h:
531         (DateTimeHourFieldElement): Remove valueAsInteger.
532         * html/shadow/DateTimeNumericFieldElement.h:
533         (DateTimeNumericFieldElement):
534         Make valueAsInteger FINAL.
535
536 2013-01-24  Hajime Morrita  <morrita@google.com>
537
538         Refactoring: The name ContainerNode::removeChildren and ContainerNde::removeAllChilren() is confusing
539         https://bugs.webkit.org/show_bug.cgi?id=107640
540
541         Reviewed by Eric Seidel.
542
543         This change renames unsafe removeAllChilren() function to
544         removeDetachedChildren() and move it to protected visibility.
545
546         In theory, the removed nodes should be detached() before. But some
547         tests violates that assumption. It should be fixed.
548
549         No new tests. No behavior change.
550
551         * dom/ContainerNode.cpp:
552         (WebCore::ContainerNode::removeDetachedChildren):
553         (WebCore::ContainerNode::takeAllChildrenFrom):
554         (WebCore::ContainerNode::~ContainerNode):
555         * dom/ContainerNode.h:
556         (ContainerNode):
557         * dom/ContainerNodeAlgorithms.h:
558         (WebCore::removeDetachedChildrenInContainer):
559         (WebCore):
560         * dom/Document.cpp:
561         (WebCore::Document::removedLastRef):
562         * dom/ShadowRoot.cpp:
563         (WebCore::ShadowRoot::~ShadowRoot):
564         * svg/SVGElementInstance.cpp:
565         (WebCore::SVGElementInstance::detach):
566         * svg/SVGElementInstance.h:
567         (SVGElementInstance):
568
569 2013-01-24  Keishi Hattori  <keishi@webkit.org>
570
571         Adjust design of the Calendar Picker
572         https://bugs.webkit.org/show_bug.cgi?id=107507
573
574         Reviewed by Kent Tamura.
575
576         Covered by existing calendar picker appearance tests.
577
578         * Resources/pagepopups/calendarPicker.css:
579         (body): Use bigger font.
580         (.calendar-picker):
581         (.month-selector):
582         (.month-selector svg):
583         (.month-selector-popup-contents):
584         (.year-month-button-left .year-month-button):
585         (.year-month-button-right .year-month-button):
586         (.days-area-container):
587         (.days-area):
588         (.day-label):
589         (.day):
590         (.available):
591         (.month-mode .day):
592         (.today-clear-area .today-button):
593         * Resources/pagepopups/calendarPicker.js:
594         (CalendarPicker.prototype.fixWindowSize): Calculate the width of today-clear-area too.
595         (YearMonthController.prototype.attachTo):
596         (YearMonthController.prototype._attachLeftButtonsTo): Use svg icons inside buttons.
597         (YearMonthController.prototype._attachRightButtonsTo): Use svg icons inside buttons.
598         (YearMonthController.prototype.setMonth):
599         (YearMonthController.prototype._handleButtonClick):
600         * Resources/pagepopups/calendarPickerMac.css: Removed.
601         * Resources/pagepopups/chromium/calendarPickerChromium.css: Added.
602         (.year-month-button):
603         (.days-area-container:focus):
604         * Resources/pagepopups/chromium/pickerCommonChromium.css: Added. Use Chrome-style buttons.
605         (button):
606         (:enabled:hover:-webkit-any(button, input[type='button'])):
607         (:enabled:active:-webkit-any(button, input[type='button'])):
608         (:disabled:-webkit-any(button, input[type='button'])):
609         (:enabled:focus:-webkit-any(button, input[type='button'])):
610         * WebCore.gyp/WebCore.gyp: Include pickerCommonChromium.css and calendarPickerChromium.css.
611         * rendering/RenderTheme.cpp: Remove extraCalendarPickerStyleSheet
612         * rendering/RenderTheme.h: Ditto.
613         * rendering/RenderThemeChromiumMac.h: Ditto.
614         * rendering/RenderThemeChromiumMac.mm: Ditto.
615         (WebCore):
616
617 2013-01-24  Kentaro Hara  <haraken@chromium.org>
618
619         Unreviewed build fix.
620
621         * page/History.h:
622         (WebCore):
623
624 2013-01-24  Beth Dakin  <bdakin@apple.com>
625
626         Fixed elements sometimes marked out-of-view if you have rubber-banded too far, 
627         affects flickr.com
628         https://bugs.webkit.org/show_bug.cgi?id=107882
629         -and corresponding-
630         <rdar://problem/13065897>
631
632         Reviewed by Simon Fraser.
633
634         It is possible to rubber band so far that our fixed object appears to be outside 
635         of the visibleContentArea(). We should use the 
636         viewportConstrainedVisibleContentRect() since that is what fixed objects are 
637         positioned based on anyway. 
638
639         * rendering/RenderLayerCompositor.cpp:
640         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
641
642 2013-01-24  Kentaro Hara  <haraken@chromium.org>
643
644         Unreviewed build fix.
645
646         * bindings/js/JSHistoryCustom.cpp:
647         (WebCore::JSHistory::state):
648
649 2013-01-24  Julien Brianceau  <jbrianceau@nds.com>
650
651         NPN_InitializeVariantWithStringCopy is wrong for platforms returning NULL from malloc(0)
652         https://bugs.webkit.org/show_bug.cgi?id=96272
653
654         Reviewed by Alexey Proskuryakov.
655
656         No new tests. This is platform dependent.
657
658         * bridge/npruntime.cpp:
659         (NPN_InitializeVariantWithStringCopy):
660
661 2013-01-24  Christian Biesinger  <cbiesinger@chromium.org>
662
663         resize property doesn't work on iframes
664         https://bugs.webkit.org/show_bug.cgi?id=9221
665
666         Reviewed by Eric Seidel.
667
668         Test: fast/css/resize-corner-tracking-transformed-iframe.html
669         and fast/css/resize-corner-tracking.html
670
671         * rendering/RenderIFrame.cpp:
672         (WebCore::RenderIFrame::requiresLayer):
673         (WebCore):
674         * rendering/RenderIFrame.h:
675         <iframe>s need a layer to be resizable, so make requiresLayer return
676         true if the css property is set.
677
678         * rendering/RenderLayer.cpp:
679         (WebCore::RenderLayer::canResize):
680         (WebCore):
681         (WebCore::RenderLayer::resize):
682         (WebCore::RenderLayer::positionOverflowControls):
683         (WebCore::RenderLayer::isPointInResizeControl):
684         (WebCore::RenderLayer::hitTestOverflowControls):
685         (WebCore::RenderLayer::hitTestLayer):
686         * rendering/RenderLayer.h:
687         (RenderLayer):
688         Add a new canResize() function and use it instead of hasOverflowClip()
689         to check whether resizing should be allowed (there's still the
690         additional check of style()->resize() != RESIZE_NONE, of course)
691
692         Make hitTestLayer return |this| when the point is inside the
693         resizer rectangle.
694
695         * rendering/RenderWidget.cpp:
696         (WebCore::RenderWidget::paint):
697         Call layer()->paintResizer() to actually paint the resizer.
698
699 2013-01-24  Kentaro Hara  <haraken@chromium.org>
700
701         Regression(r107058): Use-after-free in SerializedScriptValue::deserialize
702         https://bugs.webkit.org/show_bug.cgi?id=107792
703
704         Reviewed by Abhishek Arya.
705
706         Imagine the following call path:
707
708         (1) history.state is accessed.
709         (2) V8History::stateAccessorGetter() calls History::state(), which calls
710         HistoryItem::stateObject().
711         (3) HistoryItem holds m_stateObject as RefPtr<SerializedScriptValue>,
712         but HistoryItem::stateObject() returns SerializedScriptValue*.
713         (4) V8History::stateAccessorGetter calls SerializedScriptValue::deserialize()
714         for the SerializedScriptValue* obtained in (3).
715         (5) SerializedScriptValue::deserialize() can call history.replaceState()
716         in its deserialization process (See the test case in the Chromium bug).
717         (6) history.replaceState() replaces HistoryItem::m_stateObject.
718         This replacement destructs the original HistoryItem::m_stateObject.
719         (7) The current deserialization process can crash due to the premature destruction.
720
721         To avoid the problem, we have to pass PassRefPtr<SerializedScriptValue> around
722         instead of SerializedScriptValue*.
723
724         Test: fast/history/replacestate-nocrash.html
725
726         * bindings/v8/custom/V8HistoryCustom.cpp:
727         (WebCore::V8History::stateAccessorGetter):
728         * history/HistoryItem.h:
729         (WebCore):
730         (WebCore::HistoryItem::stateObject):
731         * loader/FrameLoader.cpp:
732         (WebCore::FrameLoader::loadInSameDocument):
733         * loader/FrameLoader.h:
734         * page/History.cpp:
735         (WebCore::History::state):
736         (WebCore::History::stateInternal):
737         * page/History.h:
738         (History):
739
740 2013-01-24  Beth Dakin  <bdakin@apple.com>
741
742         Some formerly-fixed objects scroll as if they are still fixed
743         https://bugs.webkit.org/show_bug.cgi?id=107869
744
745         Reviewed by Simon Fraser.
746
747         Removing nodes need to mark m_hasChangedProperties on the state tree, otherwise 
748         they will not be committed to the scrolling tree until something else changes, 
749         which could actually take a while. During the delay, the scrolling tree will 
750         continue to move around the formerly-fixed object as long as it still has a layer.
751         * page/scrolling/ScrollingStateTree.cpp:
752         (WebCore::ScrollingStateTree::didRemoveNode):
753
754 2013-01-24  Arko Saha  <arko@motorola.com>
755
756         Microdata: itemtype attribute must update correctly on adding or removing tokens
757         https://bugs.webkit.org/show_bug.cgi?id=106616
758
759         Reviewed by Ryosuke Niwa.
760
761         Added a new class MicroDataAttributeTokenList, it overrides setValue() method of
762         DOMSettableTokenList. setValue() is responsible to set the new attribute value for
763         a given element.
764
765         Tests: fast/dom/MicroData/microdata-domtokenlist-attribute-add-remove-tokens.html
766                fast/dom/MicroData/propertynodelist-add-remove-itemprop-tokens.html
767                fast/dom/MicroData/propertynodelist-add-remove-itemref-tokens.html
768
769         * CMakeLists.txt:
770         * GNUmakefile.list.am:
771         * Target.pri:
772         * WebCore.gypi:
773         * WebCore.vcproj/WebCore.vcproj:
774         * WebCore.xcodeproj/project.pbxproj:
775         * dom/Node.cpp:
776         (WebCore::Node::itemProp):
777         (WebCore::Node::setItemProp):
778         (WebCore::Node::itemRef):
779         (WebCore::Node::setItemRef):
780         (WebCore::Node::itemType):
781         (WebCore::Node::setItemType):
782         * dom/NodeRareData.h:
783         (WebCore::NodeMicroDataTokenLists::itemProp):
784         (WebCore::NodeMicroDataTokenLists::itemRef):
785         (WebCore::NodeMicroDataTokenLists::itemType):
786         (NodeMicroDataTokenLists):
787         * html/DOMSettableTokenList.h: Made the constructor as protected, so that we can
788         override setValue() method.
789         (DOMSettableTokenList):
790         * html/MicroDataAttributeTokenList.cpp: Added.
791         (WebCore):
792         (WebCore::MicroDataAttributeTokenList::MicroDataAttributeTokenList):
793         (WebCore::MicroDataAttributeTokenList::setValueInternal):
794         (WebCore::MicroDataAttributeTokenList::setValue): It calls
795         DOMSettableTokenList::setValue to set internal tokens and value.
796         * html/MicroDataAttributeTokenList.h: Added.
797         (WebCore):
798         (MicroDataAttributeTokenList):
799         (WebCore::MicroDataAttributeTokenList::create):
800
801 2013-01-24  Joshua Bell  <jsbell@chromium.org>
802
803         IndexedDB: Remove IDBUpgradeNeededEvent, merge with IDBVersionChangeEvent
804         https://bugs.webkit.org/show_bug.cgi?id=107754
805
806         Reviewed by Tony Chang.
807
808         The IndexedDB spec calls deleteDatabase() to fire a "blocked" event with the
809         IDBVersionChangeEvent interface which we were doing, but with an older interface - just
810         a "version" property. We were already firing an event on "versionchange" with the new
811         "oldVersion" and "newVersion" properties, but with an IDBUpgradeNeededEvent interface that
812         doesn't exist in the spec. This patch merges the event types to match the spec, including
813         that the newVersion property is null when deleting.
814
815         Test: storage/indexeddb/events.html
816               storage/indexeddb/deletedatabase-*.html
817
818         * CMakeLists.txt: Remove references to deleted files.
819         * GNUmakefile.list.am: Ditto.
820         * Modules/indexeddb/IDBDatabase.cpp:
821         (WebCore::IDBDatabase::onVersionChange): Generate IDBVersionChangeEvent.
822         * Modules/indexeddb/IDBOpenDBRequest.cpp:
823         (WebCore::IDBOpenDBRequest::onBlocked): Ditto.
824         (WebCore::IDBOpenDBRequest::onUpgradeNeeded): Ditto.
825         * Modules/indexeddb/IDBUpgradeNeededEvent.cpp: Removed.
826         * Modules/indexeddb/IDBUpgradeNeededEvent.h: Removed.
827         * Modules/indexeddb/IDBUpgradeNeededEvent.idl: Removed.
828         * Modules/indexeddb/IDBVersionChangeEvent.cpp:
829         (WebCore::IDBVersionChangeEvent::create): Take IDBAny's as old/new versions
830         may be integers, strings (for legacy databases), or null (when deleting).
831         (WebCore::IDBVersionChangeEvent::IDBVersionChangeEvent):
832         * Modules/indexeddb/IDBVersionChangeEvent.h:
833         (IDBVersionChangeEvent): Remove version property.
834         (WebCore::IDBVersionChangeEvent::oldVersion): Added new property.
835         (WebCore::IDBVersionChangeEvent::newVersion): Added new property.
836         * Modules/indexeddb/IDBVersionChangeEvent.idl: Updated properties.
837         * WebCore.gypi: Remove references to deleted files.
838         * dom/EventNames.in: Ditto.
839
840 2013-01-24  Pratik Solanki  <psolanki@apple.com>
841
842         CertificateChain functions in ResourceResponse should be inside proper ifdefs
843         https://bugs.webkit.org/show_bug.cgi?id=107865
844
845         Reviewed by Brady Eidson.
846
847         Move ResourceResponse::setCertificateChain() and ResourceResponse::certificateChain()
848         be under the same ifdefs that they are declared in.
849
850         No new tests because no change in functionality.
851
852         * platform/network/mac/ResourceResponseMac.mm:
853
854 2013-01-24  Leo Yang  <leoyang@rim.com>
855
856         [BlackBerry] Display HTML5 Appcache manifest
857         https://bugs.webkit.org/show_bug.cgi?id=107858
858
859         Reviewed by Yong Li.
860         Reviewed internally by Jeff Rogers.
861
862         MIME alias no new tests.
863
864         * platform/MIMETypeRegistry.cpp:
865         (WebCore::mimeTypeAssociationMap):
866
867 2013-01-24  Mike West  <mkwst@chromium.org>
868
869         Web Inspector: "XHR loaded!" messages should be DebugMessageLevel.
870         https://bugs.webkit.org/show_bug.cgi?id=107817
871
872         Reviewed by Pavel Feldman.
873
874         The 'XHR finished loading:' message is currently sent at
875         LogMessageLevel. Upon reflection, the only messages that should be
876         sent at that level are messages the developer generates herself via
877         'console.*' calls. This message is better categorized as 'debug'.
878
879         * inspector/InspectorConsoleAgent.cpp:
880         (WebCore::InspectorConsoleAgent::didFinishXHRLoading):
881             Change the message to DebugMessageLevel.
882
883 2013-01-24  James Robinson  <jamesr@chromium.org>
884
885         REGRESSION(140571): Crash in ScrollingCoordinator::mainThreadScrollingReasons during Frame::createView
886         https://bugs.webkit.org/show_bug.cgi?id=107868
887
888         Reviewed by Beth Dakin.
889
890         When using fixed layout mode, it's possible to update the scrollbar state of the main FrameView before
891         it's set on the main frame, which can lead to calling in to ScrollingCoordinator to compute main thread
892         scrolling regions when m_page->mainFrame()->view() is 0. In this case, we don't have any main
893         thread scrolling reasons and should just return 0.
894
895         * page/scrolling/ScrollingCoordinator.cpp:
896         (WebCore::ScrollingCoordinator::mainThreadScrollingReasons):
897
898 2013-01-24  Martin Robinson  <mrobinson@igalia.com>
899
900         Abstract the logic for appending a UChar32 onto StringBuilder
901         https://bugs.webkit.org/show_bug.cgi?id=107505
902
903         Reviewed by Darin Adler.
904
905         * css/CSSOMUtils.cpp:
906         (WebCore::serializeCharacter): Use the new StringBuilder append.
907         (WebCore::serializeIdentifier): Ditto.
908         (WebCore::serializeString): Ditto.
909         * html/parser/HTMLEntityParser.cpp:
910         (WebCore::HTMLEntityParser::consumeNamedEntity): Ditto.
911         * svg/SVGFontData.cpp:
912         (WebCore::SVGFontData::createStringWithMirroredCharacters): Ditto.
913         * xml/parser/CharacterReferenceParserInlines.h:
914         (WebCore::consumeCharacterReference): Ditto.
915         * xml/parser/XMLCharacterReferenceParser.cpp: Remove an older helper
916         superseded by StringBuilder::append.
917
918 2013-01-24  Kentaro Hara  <haraken@chromium.org>
919
920         [V8] Pass an Isolate to GetTemplate() in v8/*.cpp
921         https://bugs.webkit.org/show_bug.cgi?id=107789
922
923         Reviewed by Adam Barth.
924
925         No tests. No change in behavior.
926
927         * bindings/v8/Dictionary.cpp:
928         (WebCore::Dictionary::get):
929         * bindings/v8/PageScriptDebugServer.cpp:
930         (WebCore::retrieveFrameWithGlobalObjectCheck):
931         * bindings/v8/V8Binding.cpp:
932         (WebCore::toDOMWindow):
933         (WebCore::toScriptExecutionContext):
934         * bindings/v8/V8DOMWindowShell.cpp:
935         (WebCore::V8DOMWindowShell::clearForNavigation):
936         * bindings/v8/V8Initializer.cpp:
937         (WebCore::findFrame):
938         (WebCore::failedAccessCheckCallbackInMainThread):
939         * bindings/v8/WorkerScriptController.cpp:
940         (WebCore::WorkerScriptController::controllerForContext):
941         * bindings/v8/custom/V8DOMWindowCustom.cpp:
942         (WebCore::V8DOMWindow::eventAccessorGetter):
943         (WebCore::V8DOMWindow::eventAccessorSetter):
944         (WebCore::V8DOMWindow::toStringCallback):
945         (WebCore::toV8):
946         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
947         (WebCore::V8HTMLImageElementConstructor::GetTemplate):
948         * bindings/v8/custom/V8InjectedScriptManager.cpp:
949         (WebCore::createInjectedScriptHostV8Wrapper):
950         (WebCore::InjectedScriptManager::createInjectedScript):
951         (WebCore::InjectedScriptManager::canAccessInspectedWindow):
952         * bindings/v8/custom/V8LocationCustom.cpp:
953         (WebCore::V8Location::reloadAccessorGetter):
954         (WebCore::V8Location::replaceAccessorGetter):
955         (WebCore::V8Location::assignAccessorGetter):
956         * bindings/v8/custom/V8MessageEventCustom.cpp:
957         (WebCore::V8MessageEvent::initMessageEventCallback):
958
959 2013-01-24  Emil A Eklund  <eae@chromium.org>
960
961         [svg] Remove unnecessary rounding in SVGRootInlineBox::layoutRootBox
962         https://bugs.webkit.org/show_bug.cgi?id=107771
963
964         Reviewed by Levi Weintraub.
965         
966         SVGRootInlineBox::layoutRootBox rounds the location and size of
967         the container to the nearest enclosing integer values. Now that
968         layout uses subpixel positioning this is no longer needed and
969         results in undesirable rounding. For high-dpi screens in
970         particular this is especially noticeable as it is rounded to
971         "pixels" which can map to two our more device pixels.
972
973         Test: svg/text/text-rect-precision.html
974
975         * rendering/svg/SVGRootInlineBox.cpp:
976         (WebCore::SVGRootInlineBox::layoutRootBox):
977         Change from enclosingIntRect to enclosingLayoutRect to align to
978         the closest containing LayoutRect now that layout is done using
979         subpixel precision.
980
981 2013-01-24  Philip Rogers  <pdr@google.com>
982
983         Preserve container size requests across image loads
984         https://bugs.webkit.org/show_bug.cgi?id=106733
985
986         Reviewed by Tim Horton.
987
988         Some images, such as SVG with relative dimensions, depend on the renderer's container size.
989         r137981 introduced the ability to store pending container size requests that are made
990         after the image element lays out but before the image loads. Before this patch, cached
991         images could discard these pending container size requests during cache revalidation.
992
993         During a cached image load, two CachedImages exist: the image in cache and a new CachedImage
994         that will be used if the cache is stale. Pending container size requests are stored
995         on the second cached image which is discarded if a 304 not modified response is received.
996
997         This patch modifies the switchClientsToRevalidatedResource logic to maintain pending
998         container size requests. This fixes a bug where cached SVG images would be sized
999         incorrectly.
1000
1001         Test: http/tests/svg/cached-image-sizing.html
1002
1003         * loader/cache/CachedImage.cpp:
1004         (WebCore::CachedImage::switchClientsToRevalidatedResource):
1005
1006             In this virtual call we special-case images with pending size requests and
1007             transfer these requests to the revalidating resource. Note that all container size
1008             requests received before revalidation will be pending because the image has not loaded.
1009             Therefore, there is no risk of discarding non-pending container size requests.
1010
1011         (WebCore):
1012         * loader/cache/CachedImage.h:
1013         (CachedImage):
1014         * loader/cache/CachedResource.h:
1015         (CachedResource):
1016
1017 2013-01-24  Sheriff Bot  <webkit.review.bot@gmail.com>
1018
1019         Unreviewed, rolling out r140296.
1020         http://trac.webkit.org/changeset/140296
1021         https://bugs.webkit.org/show_bug.cgi?id=107857
1022
1023         Cause several regresssions (Requested by smfr on #webkit).
1024
1025         * rendering/RenderBox.cpp:
1026         (WebCore::RenderBox::styleDidChange):
1027
1028 2013-01-24  Mark Hahnenberg  <mhahnenberg@apple.com>
1029
1030         Objective-C API: Rename JSValue.h/APIJSValue.h to JSCJSValue.h/JSValue.h
1031         https://bugs.webkit.org/show_bug.cgi?id=107327
1032
1033         Reviewed by Filip Pizlo.
1034
1035         No new tests.
1036
1037         We're renaming these two files, so we have to replace the names everywhere.
1038
1039         * ForwardingHeaders/runtime/JSCJSValue.h: Copied from Source/WebCore/ForwardingHeaders/runtime/JSValue.h.
1040         * ForwardingHeaders/runtime/JSValue.h: Removed.
1041         * WebCore.vcproj/WebCore.vcproj:
1042         * bindings/js/JSArrayBufferViewHelper.h:
1043         * bindings/js/JSCustomXPathNSResolver.h:
1044         * bindings/js/JSHTMLAllCollectionCustom.cpp:
1045         * bindings/js/JSIntentConstructor.cpp:
1046         * bindings/js/JSMessagePortCustom.h:
1047         * bindings/js/JSNodeFilterCondition.h:
1048         * bindings/js/JavaScriptCallFrame.cpp:
1049         * bindings/js/ScriptCallStackFactory.cpp:
1050         * bindings/js/ScriptValue.h:
1051         * bindings/js/SerializedScriptValue.h:
1052         * bindings/objc/WebScriptObjectPrivate.h:
1053         * bridge/c/c_utility.h:
1054         * bridge/testbindings.cpp:
1055         * bridge/testbindings.mm:
1056         * bridge/testqtbindings.cpp:
1057         * plugins/PluginView.cpp:
1058         * plugins/blackberry/PluginViewBlackBerry.cpp:
1059         * plugins/gtk/PluginViewGtk.cpp:
1060         * plugins/mac/PluginViewMac.mm:
1061         * plugins/qt/PluginViewQt.cpp:
1062         * plugins/win/PluginViewWin.cpp:
1063
1064 2013-01-24  Jer Noble  <jer.noble@apple.com>
1065
1066         Unreviewed build fix for Mac/Lion.
1067
1068         Protect Lion from the absence of VideoToolbox.h by wrapping in #if
1069         guards.
1070
1071         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1072
1073 2013-01-24  Anders Carlsson  <andersca@apple.com>
1074
1075         Add stubbed out StorageNamespaceProxy class
1076         https://bugs.webkit.org/show_bug.cgi?id=107846
1077
1078         Reviewed by Sam Weinig.
1079
1080         Make StorageNamespace.h and StorageArea.h private headers.
1081
1082         * WebCore.xcodeproj/project.pbxproj:
1083
1084 2013-01-24  Tony Chang  <tony@chromium.org>
1085
1086         Remove document as a parameter from a few internals methods
1087         https://bugs.webkit.org/show_bug.cgi?id=107757
1088
1089         Reviewed by Hajime Morita.
1090
1091         Remove document as a parameter since there's already one associated with internals.
1092
1093         No new tests, this refactors some testing code and is covered by
1094         exisiting tests.
1095
1096         * testing/Internals.cpp:
1097         (WebCore::Internals::isPreloaded):
1098         (WebCore::Internals::createContentElement):
1099         (WebCore::Internals::absoluteCaretBounds):
1100         * testing/Internals.h:
1101         (Internals):
1102         * testing/Internals.idl:
1103
1104 2013-01-24  Mike West  <mkwst@chromium.org>
1105
1106         Web Inspector: 'console.debug' should generate messages at DebugMessageLevel.
1107         https://bugs.webkit.org/show_bug.cgi?id=107816
1108
1109         Reviewed by Pavel Feldman.
1110
1111         'console.debug' is currently aliased to 'console.log'. Since we now
1112         render debug-level messages differently to log messages, we should use
1113         the proper message level for 'console.debug'.
1114
1115         * page/Console.cpp:
1116         (WebCore::Console::debug):
1117             Replace the alias to 'console.log' with message creation at
1118             DebugMessageLevel.
1119
1120 2013-01-24  Dima Gorbik  <dgorbik@apple.com>
1121
1122         Implement :past pseudo class for the WebVTT ::cue pseudo element
1123         https://bugs.webkit.org/show_bug.cgi?id=105482
1124
1125         Reviewed by Eric Carlson.
1126
1127         It is good to have a designated pseudo class for this, though same could
1128         be achieved by using a combination of ::cue and ::cue(:future).
1129         Tests also check that nested timestamps work properly.
1130
1131         Test: media/track/track-css-matching-timestamps.html
1132
1133         * css/CSSSelector.cpp:
1134         (WebCore::CSSSelector::pseudoId):
1135         (WebCore::nameToPseudoTypeMap):
1136         (WebCore::CSSSelector::extractPseudoType):
1137         * css/CSSSelector.h:
1138         * css/SelectorChecker.cpp:
1139         (WebCore::SelectorChecker::checkOne):
1140
1141 2013-01-23  Jer Noble  <jer.noble@apple.com>
1142
1143         Mac: Avoid using k32BGRAPixelFormat on certain platforms.
1144         https://bugs.webkit.org/show_bug.cgi?id=107732
1145
1146         Reviewed by Eric Carlson.
1147
1148         Using a AVPlayerItemVideoOutput to generate ARGB pixel buffers is a potential performance
1149         hit, as the AVPlayerItemVideoOutput will send YUV buffers through a VTPixeBufferTransferSession
1150         to convert them to ARGB regardless of whether or not a given buffer will be used. Instead,
1151         ask the AVPlayerItemVideoOutput for pixel buffers in the decoder's native pixel format and use
1152         the VTPixelBufferTransferSession to convert to ARGB only those pixel buffers which were actually
1153         requested.
1154
1155         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
1156         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1157         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoOutput): Ask for the decoder's native
1158             pixel format.
1159         (WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer): Lazily create a VTPixelTransferSession
1160             and convert output pixel buffers to k32BGRAPixelFormat.
1161
1162 2013-01-24  Christian Biesinger  <cbiesinger@chromium.org>
1163
1164         Convert RenderFullScreen to use the non-deprecated flexbox
1165         https://bugs.webkit.org/show_bug.cgi?id=107746
1166
1167         Reviewed by Ojan Vafai.
1168
1169         Tests: covered by existing tests in fullscreen/.
1170
1171         * rendering/RenderFullScreen.h:
1172         * rendering/RenderFullScreen.cpp:
1173         (RenderFullScreen::RenderFullScreen):
1174         (RenderFullScreen::willBeDestroyed):
1175         Inherit from RenderFlexibleBox
1176
1177         (createFullScreenStyle):
1178         Use the new-style CSS properties (justify-content, etc)
1179
1180         * css/fullscreen.css:
1181         (video:-webkit-full-screen, audio:-webkit-full-screen):
1182         * css/fullscreenQuickTime.css:
1183         (video:-webkit-full-screen::-webkit-media-controls-panel):
1184         (video:-webkit-full-screen::-webkit-media-controls-seek-back-button):
1185         (video:-webkit-full-screen::-webkit-media-controls-return-to-realtime-button):
1186         (video:-webkit-full-screen::-webkit-media-controls-seek-forward-button):
1187         * css/mediaControlsBlackBerryFullscreen.css:
1188         (video:-webkit-full-screen::-webkit-media-controls-panel):
1189         (video:-webkit-full-screen::-webkit-media-controls-button-group-container):
1190         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-time-display-container):
1191         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-play-button):
1192         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-timeline-container):
1193         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-current-time-display):
1194         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-time-remaining-display):
1195         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-timeline):
1196         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-fullscreen-button):
1197         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-button-divider):
1198         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-button-container, video:-webkit-full-screen::-webkit-media-controls-play-button-container):
1199         (video:-webkit-full-screen::-webkit-media-controls-fullscreen-button-container):
1200         (video:-webkit-full-screen::-webkit-media-controls-play-button-container):
1201         (video:-webkit-full-screen::-webkit-media-controls-placeholder):
1202         * css/mediaControlsQtFullscreen.css:
1203         (video::-webkit-media-controls-panel):
1204         (video::-webkit-media-controls-play-button):
1205         Update fullscreen-related CSS to use the new flexbox
1206
1207 2013-01-23  Jer Noble  <jer.noble@apple.com>
1208
1209         Mac: Video appears in wrong place during pinch operations
1210         https://bugs.webkit.org/show_bug.cgi?id=107730
1211
1212         Reviewed by Eric Carlson.
1213
1214         Send the correct input and output rects, post translation and scaling,
1215         to the CIContext for drawing.
1216
1217         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1218         (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):
1219
1220 2013-01-24  Max Vujovic  <mvujovic@adobe.com>
1221
1222         [CSS Filters] CSS opacity property clips filter outsets
1223         https://bugs.webkit.org/show_bug.cgi?id=106549
1224
1225         Reviewed by Dirk Schulze.
1226
1227         Expand the transparencyClipBox for filter outsets and pass the filter output rect instead of
1228         the input rect to beginTransparencyLayers for clipping. Details below.
1229
1230         Test: css3/filters/css-opacity-with-drop-shadow.html
1231
1232         * rendering/RenderLayer.cpp:
1233         (WebCore):
1234         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
1235             Replace filter outset calcuation with a call to expandRectForFilterOutsets.
1236         (WebCore::expandRectForFilterOutsets):
1237             New method to factor out repeated filter outset calculation code.
1238         (WebCore::transparencyClipBox):
1239             After expanding the clip rect for descendants and reflection, expand it for filter
1240             outsets, so they don't get clipped when we begin a transparency layer.
1241         (WebCore::RenderLayer::paintLayerContents):
1242             Pass paintingInfo.paintDirtyRect instead of localPaintingInfo.paintDirtyRect to
1243             beginTransparencyLayers for clipping. localPaintingInfo.paintDirtyRect (aka the filter
1244             input rect) does not contain filter outsets, so they would get clipped. Now, we pass
1245             paintingInfo.paintDirtyRect (the filter output rect), which includes the filter outsets.
1246         (WebCore::RenderLayer::calculateLayerBounds):
1247             Replace filter outset calcuation with a call to expandRectForFilterOutsets.
1248         * rendering/RenderLayer.h:
1249         (RenderLayer):
1250
1251 2013-01-24  Ryosuke Niwa  <rniwa@webkit.org>
1252
1253         Fix a typo after r139838.
1254
1255         * dom/NodeRareData.h:
1256         (NodeRareData):
1257
1258 2013-01-24  Ryosuke Niwa  <rniwa@webkit.org>
1259
1260         Abandoned Memory: SVGFontElement and Corresponding SVGDocument Never Deconstructed
1261         https://bugs.webkit.org/show_bug.cgi?id=66438
1262
1263         Reviewed by Dirk Schulze.
1264
1265         The memory leak was caused by SVGFontFaceElement storing its own parent in a RefPtr.
1266
1267         Fixed the bug by storing a raw pointer instead, and clearing the pointer in removedFrom
1268         when the node detached from the document. Also added several sanity check assertions.
1269
1270         * svg/SVGFontFaceElement.cpp:
1271         (WebCore::SVGFontFaceElement::SVGFontFaceElement):
1272         (WebCore::SVGFontFaceElement::associatedFontElement):
1273         (WebCore::SVGFontFaceElement::rebuildFontFace):
1274         (WebCore::SVGFontFaceElement::insertedInto):
1275         (WebCore::SVGFontFaceElement::removedFrom):
1276         * svg/SVGFontFaceElement.h:
1277         (SVGFontFaceElement):
1278
1279 2013-01-22  Robert Hogan  <robert@webkit.org>
1280
1281         Inline Containing Only Collapsed Whitespace Not Getting a Linebox
1282         https://bugs.webkit.org/show_bug.cgi?id=31397
1283
1284         Reviewed by David Hyatt.
1285
1286         Treat inlines containing only collapsed whitespace as empty. This allows them
1287         to get a linebox.
1288
1289         Test: fast/inline/inline-containing-collapsed-whitespace-treated-as-empty.html
1290
1291         * dom/Position.cpp:
1292         (WebCore::boundingBoxLogicalHeight):
1293         (WebCore):
1294         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
1295         * rendering/InlineIterator.h:
1296         (WebCore::isEmptyInline):
1297         (WebCore):
1298         (WebCore::bidiNextShared):
1299         (WebCore::bidiFirstSkippingEmptyInlines):
1300         * rendering/RenderBlockLineLayout.cpp:
1301         (WebCore::alwaysRequiresLineBox):
1302         (WebCore::requiresLineBox):
1303         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
1304         * rendering/RenderText.cpp:
1305         * rendering/RenderText.h:
1306         (RenderText):
1307
1308 2013-01-24  Andrey Lushnikov  <lushnikov@chromium.org>
1309
1310         Web Inspector: expand more chunks in DTE
1311         https://bugs.webkit.org/show_bug.cgi?id=107698
1312
1313         Reviewed by Pavel Feldman.
1314
1315         Mock DefaultTextEditor visible area as if it is slightly larger than real one and
1316         do all chunk expandings and repaints based on this new area.
1317
1318         No new tests: no change in behaviour.
1319
1320         * inspector/front-end/DefaultTextEditor.js:
1321         (WebInspector.TextEditorChunkedPanel.prototype.findVisibleChunks):
1322
1323 2013-01-24  Victor Jaquez  <vjaquez@igalia.com>
1324
1325         [GStreamer] Implement setPreservesPitch()
1326         https://bugs.webkit.org/show_bug.cgi?id=31155
1327
1328         Enables audio pitch preservation by using the scaletempo GStreamer
1329         element when required by the MediaPlayer.
1330
1331         Reviewed by Philippe Normand.
1332
1333         No new tests, but a layout test shall be implemented at some point
1334         using WebAudio API.
1335
1336         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1337         (WebCore::MediaPlayerPrivateGStreamer::setPreservesPitch):
1338         (WebCore):
1339         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
1340         (MediaPlayerPrivateGStreamer):
1341
1342 2013-01-24  Zoltan Arvai  <zarvai@inf.u-szeged.hu>
1343
1344         Removing deleted files from WebCore/Target.pri after r140399.
1345         https://bugs.webkit.org/show_bug.cgi?id=107815
1346
1347         Reviewed by Csaba Osztrogonác.
1348
1349         * Target.pri:
1350
1351 2013-01-24  Martin Robinson  <mrobinson@igalia.com>
1352
1353         Try to fix the Qt Windows build
1354
1355         * xml/parser/XMLDocumentParserQt.cpp:
1356         (WebCore::decodeNamedEntity): Use a reinterpret_cast to const QChar* like StringQt.cpp.
1357
1358 2013-01-24  Andrey Adaikin  <aandrey@chromium.org>
1359
1360         Web Inspector: [Canvas] REGRESSION: stack traces in the replay log are gone
1361         https://bugs.webkit.org/show_bug.cgi?id=107805
1362
1363         Reviewed by Pavel Feldman.
1364
1365         The V8's Error.prepareStackTrace is now called from the Error.captureStackTrace
1366         function instead of the "stack" getter function.
1367
1368         Test: inspector/profiler/canvas2d/canvas-stack-trace.html
1369
1370         * inspector/InjectedScriptCanvasModuleSource.js:
1371         (.):
1372
1373 2013-01-23  Andrey Adaikin  <aandrey@chromium.org>
1374
1375         Web Inspector: [Canvas] UI: add a selector to capture a single canvas frame vs consecutive frames
1376         https://bugs.webkit.org/show_bug.cgi?id=107688
1377
1378         Reviewed by Pavel Feldman.
1379
1380         Allow capturing several canvas frames in a row.
1381
1382         * English.lproj/localizedStrings.js:
1383         * inspector/InjectedScriptCanvasModule.cpp:
1384         (WebCore::InjectedScriptCanvasModule::traceLog):
1385         * inspector/InjectedScriptCanvasModule.h:
1386         (InjectedScriptCanvasModule):
1387         * inspector/InjectedScriptCanvasModuleSource.js:
1388         (.):
1389         * inspector/Inspector.json:
1390         * inspector/InspectorCanvasAgent.cpp:
1391         (WebCore::InspectorCanvasAgent::getTraceLog):
1392         * inspector/InspectorCanvasAgent.h:
1393         (InspectorCanvasAgent):
1394         * inspector/front-end/CanvasProfileView.js:
1395         (WebInspector.CanvasProfileView):
1396         (WebInspector.CanvasProfileView.prototype._didReceiveTraceLog):
1397         (WebInspector.CanvasProfileView.prototype._requestTraceLog):
1398         (WebInspector.CanvasProfileType):
1399         (WebInspector.CanvasProfileType.prototype.get statusBarItems):
1400         (WebInspector.CanvasProfileType.prototype.get buttonTooltip):
1401         (WebInspector.CanvasProfileType.prototype.buttonClicked):
1402         (WebInspector.CanvasProfileType.prototype._runSingleFrameCapturing):
1403         (WebInspector.CanvasProfileType.prototype._startFrameCapturing):
1404         (WebInspector.CanvasProfileType.prototype._stopFrameCapturing.didStopCapturing):
1405         (WebInspector.CanvasProfileType.prototype._stopFrameCapturing):
1406         (WebInspector.CanvasProfileType.prototype._didStartCapturingFrame):
1407         (WebInspector.CanvasProfileType.prototype.setRecordingProfile):
1408         (WebInspector.CanvasProfileType.prototype._isSingleFrameMode):
1409         (WebInspector.CanvasProfileHeader):
1410         (WebInspector.CanvasProfileHeader.prototype._updateCapturingStatus):
1411         (WebInspector.CanvasProfileHeader.prototype._requestCapturingStatus):
1412         * inspector/front-end/ProfileLauncherView.js:
1413         (WebInspector.ProfileLauncherView):
1414         * inspector/front-end/ProfilesPanel.js:
1415         (WebInspector.ProfileType.prototype.get statusBarItems):
1416         (WebInspector.ProfilesPanel):
1417         (WebInspector.ProfilesPanel.prototype.get statusBarItems):
1418         (WebInspector.ProfilesPanel.prototype._onProfileTypeSelected):
1419         (WebInspector.ProfilesPanel.prototype._reset):
1420         (WebInspector.ProfilesPanel.prototype._showLauncherView):
1421         (WebInspector.ProfilesPanel.prototype.showProfile):
1422         (WebInspector.ProfilesPanel.prototype._updateInterface):
1423         (WebInspector.ProfilesPanel.prototype._resize):
1424
1425 2013-01-24  Andreas Kling  <akling@apple.com>
1426
1427         Add CSSSelectorList::isValid().
1428         <http://webkit.org/b/107809>
1429
1430         Reviewed by Antti Koivisto.
1431
1432         Add an isValid() method to CSSSelectorList and use that where applicable instead of checking
1433         if first() is a null pointer.
1434
1435         * css/CSSPageRule.cpp:
1436         (WebCore::CSSPageRule::setSelectorText):
1437         * css/CSSSelectorList.cpp:
1438         * css/CSSSelectorList.h:
1439         (WebCore::CSSSelectorList::isValid):
1440         (WebCore::CSSSelectorList::first):
1441         (CSSSelectorList):
1442         * css/CSSStyleRule.cpp:
1443         (WebCore::CSSStyleRule::setSelectorText):
1444         * html/shadow/HTMLContentElement.cpp:
1445         (WebCore::HTMLContentElement::validateSelect):
1446         * inspector/InspectorStyleSheet.cpp:
1447         (WebCore::checkStyleRuleSelector):
1448
1449 2013-01-24  Kai Koehne  <kai.koehne@digia.com>
1450
1451         [Qt] Webkit debug build links against release binaries of ANGLE libEGL, libGLESv2
1452         https://bugs.webkit.org/show_bug.cgi?id=106217
1453
1454         Reviewed by Jocelyn Turcotte.
1455
1456         Use libEGLd, libEGLSv2d if qtbase was compiled with ANGLE.
1457
1458         * WebCore.pri: Mirror logic of qtbase\mkspecs\features\win32\opengl.prf
1459
1460 2013-01-24  Sergio Villar Senin  <svillar@igalia.com>
1461
1462         [GTK] Unreviewed build fix.
1463
1464         Do not include the header file WebKitDOMPerformanceEntryList.h in
1465         the build sources because we do not want the DOM bindings
1466         generator to include it in webkitdomdefes.h twice.
1467
1468         * bindings/gobject/GNUmakefile.am:
1469
1470 2013-01-24  Julien BRIANCEAU   <jbrianceau@nds.com>
1471
1472         Fix Qt build (KO since r140610), typo error for QString::fromUtf16 function.
1473         https://bugs.webkit.org/show_bug.cgi?id=107803
1474
1475         Reviewed by Andreas Kling.
1476
1477         * xml/parser/XMLDocumentParserQt.cpp:
1478         (WebCore::decodeNamedEntity):
1479
1480 2013-01-24  Pavel Feldman  <pfeldman@chromium.org>
1481
1482         Web Inspector: breakpoints are not restored upon reload for scripts with script mapping.
1483         https://bugs.webkit.org/show_bug.cgi?id=107799
1484
1485         The problem is that source mapping is set after UISourceCode gets into the workspace.
1486         Breakpoint manager will now only restore breakpoints upon setting the source maps.
1487
1488         Reviewed by Alexander Pavlov.
1489
1490         * inspector/front-end/BreakpointManager.js:
1491         (WebInspector.BreakpointManager.prototype._uiSourceCodeAdded):
1492         (WebInspector.BreakpointManager.prototype._uiSourceCodeMappingChanged):
1493         * inspector/front-end/CompilerScriptMapping.js:
1494         (WebInspector.CompilerScriptMapping.prototype.get addScript.get this):
1495         (WebInspector.CompilerScriptMapping.prototype.get addScript):
1496
1497 2013-01-24  Kent Tamura  <tkent@chromium.org>
1498
1499         Refactoring: Use AtomicString for an InputType::create argument
1500         https://bugs.webkit.org/show_bug.cgi?id=107791
1501
1502         Reviewed by Kentaro Hara.
1503
1504         A string passed to InputType::create is a 'type' attribute value, which
1505         is an AtomicString. Also, InputTypeFactoryMap is created with members of
1506         InputTypeName, which are AtomicStrings. We had better use AtomicStrings
1507         for them.
1508
1509         No new tests. This is just a refactoring.
1510
1511         * html/InputType.cpp:
1512         Change the key type of InputTypeFactoryMap from String to AtomicString.
1513         (WebCore::InputType::create):
1514         Change an argument type from const String& to const AtomicString&.
1515         * html/InputType.h:
1516         (InputType): Ditto.
1517
1518 2013-01-24  Kentaro Hara  <haraken@chromium.org>
1519
1520         Unreviewed. Build fix.
1521
1522         * bindings/v8/V8DOMWrapper.cpp:
1523         (WebCore::V8DOMWrapper::isDOMWrapper):
1524
1525 2013-01-24  Andreas Kling  <akling@apple.com>
1526
1527         AX: Fix the debug build after r140658. (Constructor initializer order.)
1528
1529         * accessibility/AccessibilityNodeObject.cpp:
1530         (WebCore::AccessibilityNodeObject::AccessibilityNodeObject):
1531
1532 2013-01-24  Hajime Morrita  <morrita@google.com>
1533
1534         There are a few of wrong removeAllChildren() call
1535         https://bugs.webkit.org/show_bug.cgi?id=107790
1536
1537         Reviewed by Ryosuke Niwa.
1538
1539         removeAllChildren() is designed for trashing deleting children out.
1540         It doesn't detach() children and could have possible leak.
1541         This change replaces such removeAllChildren() usage with safer removeChildren().
1542
1543         No new tests. Covered by existing tests.
1544
1545         * html/HTMLInputElement.cpp:
1546         (WebCore::HTMLInputElement::parseAttribute):
1547         * html/InputType.cpp:
1548         (WebCore::InputType::destroyShadowSubtree):
1549         * html/ValidationMessage.cpp:
1550         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
1551         * html/parser/HTMLTreeBuilder.cpp:
1552         (WebCore::HTMLTreeBuilder::processEndTag):
1553
1554 2013-01-24  Dominic Mazzoni  <dmazzoni@google.com>
1555
1556         AX: should init an AXObject only after AXObjectCache has added it
1557         https://bugs.webkit.org/show_bug.cgi?id=107533
1558
1559         Reviewed by Chris Fleizach.
1560
1561         Initialize each AXObject after the AXObjectCache has
1562         finished adding it to its hash maps, so that it's
1563         impossible for initialization of an AXObject to result in
1564         exploring the tree and creating another AXObject instance
1565         that points to the same renderer / node.
1566
1567         Test: accessibility/duplicate-axrenderobject-crash.html
1568
1569         * accessibility/AXObjectCache.cpp:
1570         (WebCore::AXObjectCache::getOrCreate):
1571         * accessibility/AccessibilityARIAGrid.cpp:
1572         (WebCore::AccessibilityARIAGrid::create):
1573         * accessibility/AccessibilityARIAGridCell.cpp:
1574         (WebCore::AccessibilityARIAGridCell::create):
1575         * accessibility/AccessibilityARIAGridRow.cpp:
1576         (WebCore::AccessibilityARIAGridRow::create):
1577         * accessibility/AccessibilityList.cpp:
1578         (WebCore::AccessibilityList::create):
1579         * accessibility/AccessibilityListBox.cpp:
1580         (WebCore::AccessibilityListBox::create):
1581         * accessibility/AccessibilityMediaControls.cpp:
1582         (WebCore::AccessibilityMediaControl::create):
1583         (WebCore::AccessibilityMediaControlsContainer::create):
1584         (WebCore::AccessibilityMediaTimeline::create):
1585         (WebCore::AccessibilityMediaTimeDisplay::create):
1586         * accessibility/AccessibilityMenuList.cpp:
1587         (WebCore::AccessibilityMenuList::create):
1588         * accessibility/AccessibilityNodeObject.cpp:
1589         (WebCore::AccessibilityNodeObject::create):
1590         * accessibility/AccessibilityObject.h:
1591         (WebCore::AccessibilityObject::init):
1592         (AccessibilityObject):
1593         * accessibility/AccessibilityProgressIndicator.cpp:
1594         (WebCore::AccessibilityProgressIndicator::create):
1595         * accessibility/AccessibilityRenderObject.cpp:
1596         (WebCore::AccessibilityRenderObject::create):
1597         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
1598             assert that the object has been initialized
1599         * accessibility/AccessibilitySVGRoot.cpp:
1600         (WebCore::AccessibilitySVGRoot::create):
1601         * accessibility/AccessibilitySlider.cpp:
1602         (WebCore::AccessibilitySlider::create):
1603         * accessibility/AccessibilityTable.cpp:
1604         (WebCore::AccessibilityTable::create):
1605         * accessibility/AccessibilityTableCell.cpp:
1606         (WebCore::AccessibilityTableCell::create):
1607         * accessibility/AccessibilityTableRow.cpp:
1608         (WebCore::AccessibilityTableRow::create):
1609
1610 2013-01-23  Kentaro Hara  <haraken@chromium.org>
1611
1612         Implement MouseEvent constructor
1613         https://bugs.webkit.org/show_bug.cgi?id=107630
1614
1615         Reviewed by Adam Barth.
1616
1617         Spec: https://dvcs.w3.org/hg/d4e/raw-file/tip/source_respec.htm
1618
1619         The MouseEvent constructor should be implemented under a DOM4_EVENTS_CONSTRUCTOR flag.
1620         This significantly simplifies JavaScript code to construct a MouseEvent.
1621
1622         Before:
1623           event = document.createEvent("MouseEvents");
1624           event.initMouseEvent("click", true, true, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null);
1625
1626         After:
1627           event = new MouseEvent("click");
1628
1629         Test: fast/events/constructors/mouse-event-constructor.html
1630
1631         * bindings/scripts/CodeGenerator.pm:
1632         (IsSubType):
1633         (IsInheritExtendedAttribute):
1634         * bindings/scripts/CodeGeneratorV8.pm:
1635         (GenerateHeader):
1636         (GenerateNamedConstructorCallback):
1637         (GenerateImplementation):
1638         * bindings/scripts/test/V8/V8Float64Array.cpp:
1639         (WebCore):
1640         (WebCore::V8Float64Array::createWrapper):
1641         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1642         (WebCore):
1643         (WebCore::V8TestActiveDOMObject::createWrapper):
1644         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1645         (WebCore):
1646         (WebCore::V8TestCustomNamedGetter::createWrapper):
1647         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1648         (WebCore):
1649         (WebCore::V8TestEventConstructor::createWrapper):
1650         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1651         (WebCore):
1652         (WebCore::V8TestEventTarget::toEventTarget):
1653         (WebCore::V8TestEventTarget::createWrapper):
1654         * bindings/scripts/test/V8/V8TestEventTarget.h:
1655         (V8TestEventTarget):
1656         * bindings/scripts/test/V8/V8TestException.cpp:
1657         (WebCore):
1658         (WebCore::V8TestException::createWrapper):
1659         * bindings/scripts/test/V8/V8TestInterface.cpp:
1660         (WebCore):
1661         (WebCore::V8TestInterface::toActiveDOMObject):
1662         (WebCore::V8TestInterface::createWrapper):
1663         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1664         (WebCore):
1665         (WebCore::V8TestMediaQueryListListener::createWrapper):
1666         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1667         (WebCore):
1668         (WebCore::V8TestNamedConstructor::toActiveDOMObject):
1669         (WebCore::V8TestNamedConstructor::createWrapper):
1670         * bindings/scripts/test/V8/V8TestNode.cpp:
1671         (WebCore):
1672         (WebCore::V8TestNode::toEventTarget):
1673         (WebCore::V8TestNode::createWrapper):
1674         * bindings/scripts/test/V8/V8TestNode.h:
1675         (V8TestNode):
1676         * bindings/scripts/test/V8/V8TestObj.cpp:
1677         (WebCore):
1678         (WebCore::V8TestObj::createWrapper):
1679         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
1680         (WebCore):
1681         (WebCore::V8TestOverloadedConstructors::createWrapper):
1682         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1683         (WebCore):
1684         (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
1685         * bindings/v8/Dictionary.cpp:
1686         (WebCore::Dictionary::get):
1687         (WebCore):
1688         * bindings/v8/Dictionary.h:
1689         (Dictionary):
1690         * bindings/v8/NPV8Object.cpp:
1691         (WebCore::npObjectTypeInfo):
1692         * bindings/v8/V8DOMWrapper.cpp:
1693         (WebCore::V8DOMWrapper::isDOMWrapper):
1694         (WebCore):
1695         * bindings/v8/V8DOMWrapper.h:
1696         (V8DOMWrapper):
1697         * bindings/v8/WrapperTypeInfo.h:
1698         (WebCore):
1699         (WebCore::WrapperTypeInfo::toEventTarget):
1700         (WrapperTypeInfo):
1701         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
1702         (WebCore):
1703         * dom/MouseEvent.cpp:
1704         (WebCore::MouseEventInit::MouseEventInit):
1705         (WebCore):
1706         (WebCore::MouseEvent::create):
1707         (WebCore::MouseEvent::MouseEvent):
1708         * dom/MouseEvent.h:
1709         (MouseEventInit):
1710         (WebCore):
1711         (MouseEvent):
1712         (WebCore::MouseEvent::create):
1713         (WebCore::MouseEvent::button):
1714         (WebCore::MouseEvent::buttonDown):
1715         (WebCore::MouseEvent::relatedTarget):
1716         (WebCore::MouseEvent::setRelatedTarget):
1717         (WebCore::MouseEvent::clipboard):
1718         (WebCore::MouseEvent::dataTransfer):
1719         * dom/MouseEvent.idl:
1720
1721 2013-01-23  Kent Tamura  <tkent@chromium.org>
1722
1723         Add form-related instrumentations, and support 33+ features in FeatureObserver
1724         https://bugs.webkit.org/show_bug.cgi?id=107770
1725
1726         Reviewed by Kentaro Hara.
1727
1728         No new tests. This doesn't make behavior changes.
1729
1730         * page/FeatureObserver.h:
1731         - Add form-related features.
1732         - Add a Document* version of observe().
1733         - Use BitVector to represent features to support 33+ features.
1734         (WebCore::FeatureObserver::didObserve):
1735         (FeatureObserver):
1736         * page/FeatureObserver.cpp:
1737         (WebCore::FeatureObserver::FeatureObserver):
1738         (WebCore::FeatureObserver::~FeatureObserver):
1739         (WebCore::FeatureObserver::observe):
1740
1741         * html/ColorInputType.cpp:
1742         (WebCore::ColorInputType::create): Calls FeatureObserver::observe.
1743         * html/DateInputType.cpp:
1744         (WebCore::DateInputType::create): Ditto.
1745         * html/DateTimeInputType.cpp:
1746         (WebCore::DateTimeInputType::create): Ditto.
1747         * html/DateTimeLocalInputType.cpp:
1748         (WebCore::DateTimeLocalInputType::create): Ditto.
1749         * html/EmailInputType.cpp:
1750         (WebCore::EmailInputType::create): Ditto.
1751         * html/HTMLDataListElement.cpp:
1752         (WebCore::HTMLDataListElement::create): Ditto.
1753         * html/HTMLFormControlElement.cpp:
1754         (WebCore::HTMLFormControlElement::parseAttribute): Ditto.
1755         * html/HTMLInputElement.cpp:
1756         (WebCore::HTMLInputElement::parseAttribute): Ditto.
1757         * html/HTMLTextFormControlElement.cpp:
1758         (WebCore::HTMLTextFormControlElement::parseAttribute): Ditto.
1759         * html/InputType.cpp:
1760         (WebCore::InputType::create):
1761         Record type=datetime and type=week even if these types are not enabled.
1762         * html/MonthInputType.cpp:
1763         (WebCore::MonthInputType::create): Calls FeatureObserver::observe.
1764         * html/NumberInputType.cpp:
1765         (WebCore::NumberInputType::create): Ditto.
1766         * html/RangeInputType.cpp:
1767         (WebCore::RangeInputType::create): Ditto.
1768         * html/SearchInputType.cpp:
1769         (WebCore::SearchInputType::create): Ditto.
1770         * html/TelephoneInputType.cpp:
1771         (WebCore::TelephoneInputType::create): Ditto.
1772         * html/TimeInputType.cpp:
1773         (WebCore::TimeInputType::create): Ditto.
1774         * html/URLInputType.cpp:
1775         (WebCore::URLInputType::create): Ditto.
1776         * html/WeekInputType.cpp:
1777         (WebCore::WeekInputType::create): Ditto.
1778
1779 2013-01-23  Ken Kania  <kkania@chromium.org>
1780
1781         [Inspector] Add events for tracking page loads and scheduled navigations.
1782         https://bugs.webkit.org/show_bug.cgi?id=104168
1783
1784         Reviewed by Pavel Feldman.
1785
1786         These events are needed for clients who need to be aware of when a page is
1787         navigating or about to navigate. Some clients may wish to prevent interaction
1788         with the page during this time. Two of the new events track loading start and
1789         stop, as measured by the ProgressTracker. The other two events track when a
1790         page has a new scheduled navigation and when it no longer has a scheduled
1791         navigation. These latter two events won't allow the client to determine if
1792         a load is going to happen in all circumstances, but is sufficient for many cases.
1793         Make sure we hold a reference to the frame in NavigationScheduler::timerFired
1794         in case the redirect causes the frame to be detached.
1795
1796         Also, minor update to InspectorInputAgent::dispatchMouseEvent to reorder params
1797         to match dispatchKeyEvent.
1798
1799         Tests: inspector-protocol/page/frameScheduledNavigation.html
1800                inspector-protocol/page/frameStartedLoading.html
1801
1802         * inspector/Inspector.json:
1803         * inspector/InspectorInputAgent.cpp:
1804         (WebCore::InspectorInputAgent::dispatchMouseEvent):
1805         * inspector/InspectorInputAgent.h:
1806         (InspectorInputAgent):
1807         * inspector/InspectorInstrumentation.cpp:
1808         (WebCore):
1809         (WebCore::InspectorInstrumentation::frameStartedLoadingImpl):
1810         (WebCore::InspectorInstrumentation::frameStoppedLoadingImpl):
1811         (WebCore::InspectorInstrumentation::frameScheduledNavigationImpl):
1812         (WebCore::InspectorInstrumentation::frameClearedScheduledNavigationImpl):
1813         * inspector/InspectorInstrumentation.h:
1814         (InspectorInstrumentation):
1815         (WebCore::InspectorInstrumentation::frameStartedLoading):
1816         (WebCore):
1817         (WebCore::InspectorInstrumentation::frameStoppedLoading):
1818         (WebCore::InspectorInstrumentation::frameScheduledNavigation):
1819         (WebCore::InspectorInstrumentation::frameClearedScheduledNavigation):
1820         * inspector/InspectorPageAgent.cpp:
1821         (WebCore::InspectorPageAgent::frameStartedLoading):
1822         (WebCore):
1823         (WebCore::InspectorPageAgent::frameStoppedLoading):
1824         (WebCore::InspectorPageAgent::frameScheduledNavigation):
1825         (WebCore::InspectorPageAgent::frameClearedScheduledNavigation):
1826         * inspector/InspectorPageAgent.h:
1827         * inspector/front-end/ResourceTreeModel.js:
1828         (WebInspector.PageDispatcher.prototype.frameDetached):
1829         (WebInspector.PageDispatcher.prototype.frameStartedLoading):
1830         (WebInspector.PageDispatcher.prototype.frameStoppedLoading):
1831         (WebInspector.PageDispatcher.prototype.frameScheduledNavigation):
1832         (WebInspector.PageDispatcher.prototype.frameClearedScheduledNavigation):
1833         * loader/NavigationScheduler.cpp:
1834         (WebCore::NavigationScheduler::clear):
1835         (WebCore::NavigationScheduler::timerFired):
1836         (WebCore::NavigationScheduler::startTimer):
1837         (WebCore::NavigationScheduler::cancel):
1838         * loader/ProgressTracker.cpp:
1839         (WebCore::ProgressTracker::progressStarted):
1840         (WebCore::ProgressTracker::finalProgressComplete):
1841
1842 2013-01-23  Simon Fraser  <simon.fraser@apple.com>
1843
1844         Avoid creating background layers on pages with a fixed background, but no image
1845         https://bugs.webkit.org/show_bug.cgi?id=107783
1846         <rdar://problem/13074450>
1847
1848         Reviewed by Beth Dakin.
1849         
1850         http://www.nme.com has background-attachment: fixed on the <body>, but
1851         not background image. In that case there's no point making a layer
1852         for the fixed root background.
1853
1854         Test: platform/mac/tiled-drawing/fixed-background/fixed-background-no-image.html
1855
1856         * rendering/style/RenderStyle.cpp:
1857         (WebCore::allLayersAreFixed): Check to see if we have an image, as well
1858         as fixed attachment.
1859
1860 2013-01-23  Wei Jia  <wjia@chromium.org>
1861
1862         Enable autoplay when <video>'s src is from media stream
1863         https://bugs.webkit.org/show_bug.cgi?id=105224
1864
1865         Reviewed by Eric Carlson.
1866
1867         Enable autoplay when <video>'s src is from media stream. This would avoid requesting multiple gestures when <video> is used for WebRTC.
1868         The test is done by modifying platform/chromium/media/video-capture-preview.html.
1869
1870         * html/HTMLMediaElement.cpp:
1871         (WebCore::HTMLMediaElement::loadResource):
1872
1873 2013-01-23  Roger Fong  <roger_fong@apple.com>
1874
1875         Remove ForwardingHeaders/wtf from WebCore.
1876         https://bugs.webkit.org/show_bug.cgi?id=107723
1877
1878         The folders are empty, nothings actually being copied over anymore from the ForwardingHeaders/wtf folder.
1879
1880         Reviewed by Benjamin Poulain.
1881
1882         * ForwardingHeaders/wtf: Removed.
1883         * ForwardingHeaders/wtf/dtoa: Removed.
1884         * ForwardingHeaders/wtf/text: Removed.
1885         * ForwardingHeaders/wtf/unicode: Removed.
1886         * ForwardingHeaders/wtf/unicode/icu: Removed.
1887         * ForwardingHeaders/wtf/unicode/wince: Removed.
1888         * ForwardingHeaders/wtf/url: Removed.
1889         * WebCore.vcproj/copyForwardingHeaders.cmd:
1890
1891 2013-01-23  Hayato Ito  <hayato@chromium.org>
1892
1893         Group parameters (firstRuleIndex and lastRuleIndex) into a parameter object, RuleRange.
1894         https://bugs.webkit.org/show_bug.cgi?id=107095
1895
1896         Reviewed by Darin Adler.
1897
1898         This is a continued effort after r139817.
1899
1900         Factoring, no change in behavior.
1901
1902         * css/StyleResolver.cpp:
1903         (WebCore::StyleResolver::collectMatchingRules):
1904         (WebCore::StyleResolver::collectMatchingRulesForRegion):
1905         (WebCore::StyleResolver::matchScopedAuthorRules):
1906         (WebCore::StyleResolver::matchHostRules):
1907         (WebCore::StyleResolver::matchAuthorRules):
1908         (WebCore::StyleResolver::matchUserRules):
1909         (WebCore::StyleResolver::matchUARules):
1910         (WebCore::StyleResolver::collectMatchingRulesForList):
1911         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
1912         * css/StyleResolver.h:
1913         (WebCore::StyleResolver::RuleRange::RuleRange):
1914         (RuleRange): Newly introduced to group parameters.
1915         (StyleResolver):
1916         (WebCore::StyleResolver::MatchRanges::UARuleRange):
1917         (WebCore::StyleResolver::MatchRanges::authorRuleRange):
1918         (WebCore::StyleResolver::MatchRanges::userRuleRange):
1919
1920 2013-01-23  Luke Macpherson   <macpherson@chromium.org>
1921
1922         Support variables inside -webkit-box-reflect CSS property.
1923         https://bugs.webkit.org/show_bug.cgi?id=106856
1924
1925         Reviewed by Tony Chang.
1926
1927         The primary change is to make the direction parameter a CSSPrimitiveValue style ident,
1928         so that it can also be a variable reference.
1929
1930         Covered by existing LayoutTests/compositing/reflections/ tests.
1931         Added Test: fast/css/variables/var-inside-box-reflect.html
1932
1933         * css/CSSComputedStyleDeclaration.cpp:
1934         (WebCore::valueForReflection):
1935         * css/CSSParser.cpp:
1936         (WebCore::CSSParser::parseReflect):
1937         * css/CSSPrimitiveValueMappings.h:
1938         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1939         (WebCore):
1940         (WebCore::CSSPrimitiveValue::operator CSSReflectionDirection):
1941         (WebCore::CSSPrimitiveValue::convertToLength):
1942         * css/CSSReflectValue.cpp:
1943         (WebCore::CSSReflectValue::customCssText):
1944         Use String addition operator instead of StringBuilder.
1945         (WebCore):
1946         (WebCore::CSSReflectValue::customSerializeResolvingVariables):
1947         Use String addition operator instead of StringBuilder.
1948         * css/CSSReflectValue.h:
1949         (WebCore::CSSReflectValue::create):
1950         (WebCore::CSSReflectValue::direction):
1951         (CSSReflectValue):
1952         (WebCore::CSSReflectValue::CSSReflectValue):
1953         * css/CSSValue.cpp:
1954         (WebCore::CSSValue::serializeResolvingVariables):
1955         * css/StyleResolver.cpp:
1956         (WebCore::hasVariableReference):
1957         (WebCore::StyleResolver::applyProperty):
1958
1959 2013-01-23  Abhishek Arya  <inferno@chromium.org>
1960
1961         Add ASSERT_WITH_SECURITY_IMPLICATION to detect bad casts in rendering
1962         https://bugs.webkit.org/show_bug.cgi?id=107743
1963
1964         Reviewed by Eric Seidel.
1965
1966         * rendering/InlineFlowBox.h:
1967         (WebCore::toInlineFlowBox):
1968         * rendering/RenderBR.h:
1969         (WebCore::toRenderBR):
1970         * rendering/RenderBlock.h:
1971         (WebCore::toRenderBlock):
1972         * rendering/RenderBox.h:
1973         (WebCore::toRenderBox):
1974         * rendering/RenderBoxModelObject.h:
1975         (WebCore::toRenderBoxModelObject):
1976         * rendering/RenderButton.h:
1977         (WebCore::toRenderButton):
1978         * rendering/RenderCombineText.h:
1979         (WebCore::toRenderCombineText):
1980         * rendering/RenderCounter.h:
1981         (WebCore::toRenderCounter):
1982         * rendering/RenderDetailsMarker.h:
1983         (WebCore::toRenderDetailsMarker):
1984         * rendering/RenderEmbeddedObject.h:
1985         (WebCore::toRenderEmbeddedObject):
1986         * rendering/RenderFieldset.h:
1987         (WebCore::toRenderFieldset):
1988         * rendering/RenderFileUploadControl.h:
1989         (WebCore::toRenderFileUploadControl):
1990         * rendering/RenderFlowThread.h:
1991         (WebCore::toRenderFlowThread):
1992         * rendering/RenderFrame.h:
1993         (WebCore::toRenderFrame):
1994         * rendering/RenderFrameSet.h:
1995         (WebCore::toRenderFrameSet):
1996         * rendering/RenderFullScreen.h:
1997         (WebCore::toRenderFullScreen):
1998         * rendering/RenderIFrame.h:
1999         (WebCore::toRenderIFrame):
2000         * rendering/RenderImage.h:
2001         (WebCore::toRenderImage):
2002         * rendering/RenderInline.h:
2003         (WebCore::toRenderInline):
2004         * rendering/RenderLayerModelObject.h:
2005         (WebCore::toRenderLayerModelObject):
2006         * rendering/RenderListBox.h:
2007         (WebCore::toRenderListBox):
2008         * rendering/RenderListItem.h:
2009         (WebCore::toRenderListItem):
2010         * rendering/RenderListMarker.h:
2011         (WebCore::toRenderListMarker):
2012         * rendering/RenderMedia.h:
2013         (WebCore::toRenderMedia):
2014         * rendering/RenderMenuList.h:
2015         (WebCore::toRenderMenuList):
2016         * rendering/RenderMeter.h:
2017         (WebCore::toRenderMeter):
2018         * rendering/RenderMultiColumnBlock.h:
2019         (WebCore::toRenderMultiColumnBlock):
2020         * rendering/RenderMultiColumnSet.h:
2021         (WebCore::toRenderMultiColumnSet):
2022         * rendering/RenderNamedFlowThread.h:
2023         (WebCore::toRenderNamedFlowThread):
2024         * rendering/RenderPart.h:
2025         (WebCore::toRenderPart):
2026         * rendering/RenderProgress.h:
2027         (WebCore::toRenderProgress):
2028         * rendering/RenderQuote.h:
2029         (WebCore::toRenderQuote):
2030         * rendering/RenderRegion.h:
2031         (WebCore::toRenderRegion):
2032         * rendering/RenderRubyRun.h:
2033         (WebCore::toRenderRubyRun):
2034         * rendering/RenderScrollbarPart.h:
2035         (WebCore::toRenderScrollbarPart):
2036         * rendering/RenderSearchField.h:
2037         (WebCore::toRenderSearchField):
2038         * rendering/RenderSlider.h:
2039         (WebCore::toRenderSlider):
2040         * rendering/RenderSnapshottedPlugIn.h:
2041         (WebCore::toRenderSnapshottedPlugIn):
2042         * rendering/RenderTable.h:
2043         (WebCore::toRenderTable):
2044         * rendering/RenderTableCaption.h:
2045         (WebCore::toRenderTableCaption):
2046         * rendering/RenderTableCell.h:
2047         (WebCore::toRenderTableCell):
2048         * rendering/RenderTableCol.h:
2049         (WebCore::toRenderTableCol):
2050         * rendering/RenderTableRow.h:
2051         (WebCore::toRenderTableRow):
2052         * rendering/RenderTableSection.h:
2053         (WebCore::toRenderTableSection):
2054         * rendering/RenderText.h:
2055         (WebCore::toRenderText):
2056         * rendering/RenderTextControl.h:
2057         (WebCore::toRenderTextControl):
2058         * rendering/RenderTextControlMultiLine.h:
2059         (WebCore::toRenderTextControlMultiLine):
2060         * rendering/RenderTextControlSingleLine.h:
2061         (WebCore::toRenderTextControlSingleLine):
2062         * rendering/RenderVideo.h:
2063         (WebCore::toRenderVideo):
2064         * rendering/RenderView.h:
2065         (WebCore::toRenderView):
2066         * rendering/RenderWidget.h:
2067         (WebCore::toRenderWidget):
2068         * rendering/mathml/RenderMathMLBlock.h:
2069         (WebCore::toRenderMathMLBlock):
2070         * rendering/svg/RenderSVGContainer.h:
2071         (WebCore::toRenderSVGContainer):
2072         * rendering/svg/RenderSVGGradientStop.h:
2073         (WebCore::toRenderSVGGradientStop):
2074         * rendering/svg/RenderSVGImage.h:
2075         (WebCore::toRenderSVGImage):
2076         * rendering/svg/RenderSVGInlineText.h:
2077         (WebCore::toRenderSVGInlineText):
2078         * rendering/svg/RenderSVGRoot.h:
2079         (WebCore::toRenderSVGRoot):
2080         * rendering/svg/RenderSVGShape.h:
2081         (WebCore::toRenderSVGShape):
2082         * rendering/svg/RenderSVGText.h:
2083         (WebCore::toRenderSVGText):
2084
2085 2013-01-23  Elliott Sprehn  <esprehn@gmail.com>
2086
2087         Don't allocate rare data on every Element on removal
2088         https://bugs.webkit.org/show_bug.cgi?id=107756
2089
2090         Reviewed by Eric Seidel.
2091
2092         We should not allocate an ElementRareData for every element
2093         in Element::removedFrom. Previously calls to setIsInTopLayer
2094         would unconditionally call ensureElementRareData(), and this was
2095         called from Element::removedFrom meaning removing an element
2096         made the entire subtree suddenly balloon to huge in size as each
2097         one got an ElementRareData.
2098
2099         This is a regression from my patch on Bug 103912 where I removed a check
2100         that avoided this allocation.
2101
2102         No new tests needed, covered by existing tests.
2103
2104         * dom/Element.cpp:
2105         (WebCore::Element::setIsInTopLayer):
2106
2107 2013-01-23  Adam Barth  <abarth@webkit.org>
2108
2109         BackgroundHTMLParser should use more const references to avoid copy constructors
2110         https://bugs.webkit.org/show_bug.cgi?id=107763
2111
2112         Reviewed by Tony Gentilcore.
2113
2114         I doubt this optimization is visible anywhere, but it's just a nit.
2115
2116         * html/parser/BackgroundHTMLParser.cpp:
2117         (WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
2118         (WebCore::BackgroundHTMLParser::createPartial):
2119         * html/parser/BackgroundHTMLParser.h:
2120         (WebCore::BackgroundHTMLParser::create):
2121         (BackgroundHTMLParser):
2122
2123 2013-01-23  Abhishek Arya  <inferno@chromium.org>
2124
2125         Add support for ASSERT_WITH_SECURITY_IMPLICATION.
2126         https://bugs.webkit.org/show_bug.cgi?id=107699
2127
2128         Reviewed by Eric Seidel.
2129
2130         * dom/ContainerNode.cpp:
2131         (WebCore::ContainerNode::parserInsertBefore): Use ASSERT_WITH_SECURITY_IMPLICATION
2132         for document confusion ASSERT(document() == newChild->document())
2133         (WebCore::ContainerNode::parserAppendChild): same.
2134
2135 2013-01-23  Ian Vollick  <vollick@chromium.org>
2136
2137         Unreviewed build fix.
2138
2139         * rendering/RenderLayer.cpp:
2140         (WebCore::RenderLayer::rebuildZOrderLists):
2141
2142 2013-01-23  Rafael Weinstein  <rafaelw@chromium.org>
2143
2144         Template element should parse in XHTML just as it does in HTML
2145         https://bugs.webkit.org/show_bug.cgi?id=106491
2146
2147         Reviewed by Ryosuke Niwa.
2148
2149         https://dvcs.w3.org/hg/webcomponents/raw-file/f33622c39c5e/spec/templates/index.html#parsing-xhtml-documents.
2150         https://dvcs.w3.org/hg/webcomponents/raw-file/f33622c39c5e/spec/templates/index.html#serializing-xhtml-documents.
2151
2152         This patch modifies the XML parser in two ways: (1) when nodes are created, their owner document is
2153         the owner document of the current node, rather than the containing document, and (2) when an HTMLTemplateElement
2154         is encountered, its content document fragment is pushed onto the stack, rather than the element itself, so that children
2155         are appended to the template content. Also, because XSLT operates on the serialized input document, transforms consider
2156         template contents to be descendants.
2157
2158         Tests: fast/dom/HTMLTemplateElement/xhtml-parsing-and-serialization.xml
2159                fast/xpath/xpath-template-element.html
2160                fast/xsl/xslt-processor-template.html
2161                fast/xsl/xslt-xhtml-template.xml
2162
2163         * xml/parser/XMLDocumentParser.cpp:
2164         (WebCore::XMLDocumentParser::enterText):
2165         * xml/parser/XMLDocumentParserLibxml2.cpp:
2166         (WebCore::XMLDocumentParser::startElementNs):
2167         (WebCore::XMLDocumentParser::processingInstruction):
2168         (WebCore::XMLDocumentParser::cdataBlock):
2169         (WebCore::XMLDocumentParser::comment):
2170
2171 2013-01-23  Tony Gentilcore  <tonyg@chromium.org>
2172
2173         Teach threaded HTML parser to update InspectorInstrumentation when writing HTML
2174         https://bugs.webkit.org/show_bug.cgi?id=107755
2175
2176         Reviewed by Eric Seidel.
2177
2178         The current length is unused, so it doesn't cause any noticeable behavior difference to not pass it here.
2179
2180         No new tests because covered by existing tests.
2181
2182         * html/parser/HTMLDocumentParser.cpp:
2183         (WebCore::HTMLDocumentParser::processTokensFromBackgroundParser):
2184
2185 2013-01-23  Kentaro Hara  <haraken@chromium.org>
2186
2187         [V8] Make an Isolate parameter mandatory in NativeToJS()
2188         https://bugs.webkit.org/show_bug.cgi?id=107663
2189
2190         Reviewed by Adam Barth.
2191
2192         No tests. No change in behavior.
2193
2194         * bindings/scripts/CodeGeneratorV8.pm:
2195         (GenerateCallbackImplementation):
2196         (NativeToJSValue):
2197         * bindings/scripts/test/V8/V8TestCallback.cpp:
2198         (WebCore::V8TestCallback::callbackWithClass1Param):
2199         (WebCore::V8TestCallback::callbackWithClass2Param):
2200         (WebCore::V8TestCallback::callbackWithStringList):
2201         (WebCore::V8TestCallback::callbackWithBoolean):
2202         (WebCore::V8TestCallback::callbackRequiresThisToPass):
2203
2204 2013-01-23  Stephanie Lewis  <slewis@apple.com>
2205
2206         Add ordering for WebCore __DATA.
2207         https://bugs.webkit.org/show_bug.cgi?id=107765
2208         <rdar://problem/13019603>
2209
2210         Rubber stamped by Oliver Hunt.
2211
2212         No Change in functionality.
2213
2214         * WebCore.order:
2215
2216 2013-01-23  Benjamin Poulain  <bpoulain@apple.com>
2217
2218         RenderProgress does not repaint on value change
2219         https://bugs.webkit.org/show_bug.cgi?id=106977
2220
2221         Reviewed by Joseph Pecoraro.
2222
2223         No test because the ouput depends on the code of RenderTheme, and
2224         we use the platform theme for testing.
2225
2226         * rendering/RenderProgress.cpp:
2227         (WebCore::RenderProgress::updateFromElement):
2228         (WebCore::RenderProgress::updateAnimationState):
2229         Previously, repaint() was only called on two occasions:
2230         -On animationTimerFired().
2231         -In response to updateFromElement() if and only if the RenderTheme start/stop an
2232          animation previously stopped/running.
2233
2234         When changing the value of HTMLProgressElement, no repaint was called until
2235         the next timer fired for the animation.
2236         This is a problem if:
2237         -The animation of RenderTheme is slow.
2238         -If there is no animation (the element is never updated in that case).
2239
2240 2013-01-23  Ian Vollick  <vollick@chromium.org>
2241
2242         Introduce the "stacking container" concept.
2243         https://bugs.webkit.org/show_bug.cgi?id=107734
2244
2245         Reviewed by Simon Fraser.
2246
2247         A stacking container is treated just like a stacking context. That
2248         is, it has z-order lists, it and its descendants are stacked as a
2249         unit, and when the RenderLayerCompositor does its overlap testing,
2250         the composited regions for all layer lists take effect only once the
2251         stacking container is done being processed.
2252
2253         This patch also adds the function RenderLayer::isStackingContainer().
2254         Currently, this is equivalent to RenderLayer::isStackingContext(),
2255         but in future, the definition of stacking container will be broadened
2256         to encompass more than just stacking contexts.
2257
2258         Other than the addition of this extra function, the patch is mostly
2259         comprised of name changes. Any code that used to refer to the
2260         stacking context concept, but didn't necessarily require a stacking
2261         context in the strict, CSS-sense, was switched to refer to stacking
2262         container. No functionality was changed.
2263
2264         No new tests, no change in functionality.
2265
2266         * inspector/InspectorLayerTreeAgent.cpp:
2267         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
2268         * rendering/RenderLayer.cpp:
2269         (WebCore::RenderLayer::RenderLayer):
2270         (WebCore):
2271         (WebCore::RenderLayer::updatePagination):
2272         (WebCore::RenderLayer::canBeStackingContainer):
2273         (WebCore::RenderLayer::setHasVisibleContent):
2274         (WebCore::RenderLayer::dirty3DTransformedDescendantStatus):
2275         (WebCore::RenderLayer::stackingContainer):
2276         (WebCore::compositingContainer):
2277         (WebCore::expandClipRectForDescendantsAndReflection):
2278         (WebCore::RenderLayer::addChild):
2279         (WebCore::RenderLayer::removeChild):
2280         (WebCore::RenderLayer::updateNeedsCompositedScrolling):
2281         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
2282         (WebCore::RenderLayer::paintPaginatedChildLayer):
2283         (WebCore::RenderLayer::hitTestPaginatedChildLayer):
2284         (WebCore::RenderLayer::calculateLayerBounds):
2285         (WebCore::RenderLayer::dirtyZOrderLists):
2286         (WebCore::RenderLayer::dirtyStackingContainerZOrderLists):
2287         (WebCore::RenderLayer::collectLayers):
2288         (WebCore::RenderLayer::updateCompositingAndLayerListsIfNeeded):
2289         (WebCore::RenderLayer::updateStackingContextsAfterStyleChange):
2290         (WebCore::RenderLayer::styleChanged):
2291         * rendering/RenderLayer.h:
2292         (RenderLayer):
2293         (WebCore::RenderLayer::isStackingContainer):
2294         (WebCore::RenderLayer::posZOrderList):
2295         (WebCore::RenderLayer::negZOrderList):
2296         (WebCore::RenderLayer::isDirtyStackingContainer):
2297         (WebCore::RenderLayer::clearZOrderLists):
2298         (WebCore::RenderLayer::updateZOrderLists):
2299         * rendering/RenderLayerBacking.cpp:
2300         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2301         (WebCore::RenderLayerBacking::compositingOpacity):
2302         (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers):
2303         * rendering/RenderLayerCompositor.cpp:
2304         (WebCore::RenderLayerCompositor::enclosingNonStackingClippingLayer):
2305         (WebCore::RenderLayerCompositor::addToOverlapMapRecursive):
2306         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
2307         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2308         (WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
2309         (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
2310         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2311         (WebCore::RenderLayerCompositor::layerHas3DContent):
2312         (WebCore::isRootmostFixedOrStickyLayer):
2313
2314 2013-01-23  Simon Fraser  <simon.fraser@apple.com>
2315
2316         Have scrollperf logging log information about wheel event handlers
2317         https://bugs.webkit.org/show_bug.cgi?id=107761
2318         <rdar://problem/12281015>
2319
2320         Reviewed by Tim Horton.
2321
2322         Log when the wheel event handler count of a ScrollingTreeScrollingNodeMac changes.
2323
2324         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2325         (WebCore::ScrollingTreeScrollingNodeMac::update):
2326         (WebCore::logWheelEventHandlerCountChanged):
2327
2328 2013-01-23  Kentaro Hara  <haraken@chromium.org>
2329
2330         [V8] Add an optional Isolate parameter to GetTemplate() and GetRawTemplate()
2331         https://bugs.webkit.org/show_bug.cgi?id=107679
2332
2333         Reviewed by Adam Barth.
2334
2335         It is important to pass an Isolate to GetTemplate() and GetRawTemplate().
2336         To proceed the work incrementally, this patch adds an optional Isolate parameter
2337         to GetTemplate() and GetRawTemplate(). Once all call sites are updated, the
2338         Isolate parameter will be made mandatory.
2339
2340         No tests. No change in behavior.
2341
2342         * bindings/scripts/CodeGeneratorV8.pm:
2343         (GenerateHeader):
2344         (GenerateNamedConstructorCallback):
2345         (GenerateImplementation):
2346         * bindings/scripts/test/V8/V8Float64Array.cpp:
2347         (WebCore::V8Float64Array::GetRawTemplate):
2348         (WebCore::V8Float64Array::GetTemplate):
2349         * bindings/scripts/test/V8/V8Float64Array.h:
2350         (V8Float64Array):
2351         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2352         (WebCore::V8TestActiveDOMObject::GetRawTemplate):
2353         (WebCore::V8TestActiveDOMObject::GetTemplate):
2354         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2355         (V8TestActiveDOMObject):
2356         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2357         (WebCore::V8TestCustomNamedGetter::GetRawTemplate):
2358         (WebCore::V8TestCustomNamedGetter::GetTemplate):
2359         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2360         (V8TestCustomNamedGetter):
2361         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2362         (WebCore::V8TestEventConstructor::GetRawTemplate):
2363         (WebCore::V8TestEventConstructor::GetTemplate):
2364         * bindings/scripts/test/V8/V8TestEventConstructor.h:
2365         (V8TestEventConstructor):
2366         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2367         (WebCore::V8TestEventTarget::GetRawTemplate):
2368         (WebCore::V8TestEventTarget::GetTemplate):
2369         * bindings/scripts/test/V8/V8TestEventTarget.h:
2370         (V8TestEventTarget):
2371         * bindings/scripts/test/V8/V8TestException.cpp:
2372         (WebCore::V8TestException::GetRawTemplate):
2373         (WebCore::V8TestException::GetTemplate):
2374         * bindings/scripts/test/V8/V8TestException.h:
2375         (V8TestException):
2376         * bindings/scripts/test/V8/V8TestInterface.cpp:
2377         (WebCore::V8TestInterface::GetRawTemplate):
2378         (WebCore::V8TestInterface::GetTemplate):
2379         * bindings/scripts/test/V8/V8TestInterface.h:
2380         (V8TestInterface):
2381         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2382         (WebCore::V8TestMediaQueryListListener::GetRawTemplate):
2383         (WebCore::V8TestMediaQueryListListener::GetTemplate):
2384         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2385         (V8TestMediaQueryListListener):
2386         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2387         (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
2388         (WebCore::V8TestNamedConstructor::GetRawTemplate):
2389         (WebCore::V8TestNamedConstructor::GetTemplate):
2390         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2391         (V8TestNamedConstructorConstructor):
2392         (V8TestNamedConstructor):
2393         * bindings/scripts/test/V8/V8TestNode.cpp:
2394         (WebCore::V8TestNode::GetRawTemplate):
2395         (WebCore::V8TestNode::GetTemplate):
2396         * bindings/scripts/test/V8/V8TestNode.h:
2397         (V8TestNode):
2398         * bindings/scripts/test/V8/V8TestObj.cpp:
2399         (WebCore::V8TestObj::GetRawTemplate):
2400         (WebCore::V8TestObj::GetTemplate):
2401         * bindings/scripts/test/V8/V8TestObj.h:
2402         (V8TestObj):
2403         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
2404         (WebCore::V8TestOverloadedConstructors::GetRawTemplate):
2405         (WebCore::V8TestOverloadedConstructors::GetTemplate):
2406         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
2407         (V8TestOverloadedConstructors):
2408         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2409         (WebCore::V8TestSerializedScriptValueInterface::GetRawTemplate):
2410         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
2411         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2412         (V8TestSerializedScriptValueInterface):
2413         * bindings/v8/WrapperTypeInfo.h:
2414         (WebCore):
2415         (WebCore::WrapperTypeInfo::getTemplate):
2416         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
2417         (WebCore::V8HTMLImageElementConstructor::GetTemplate):
2418         * bindings/v8/custom/V8HTMLImageElementConstructor.h:
2419         (V8HTMLImageElementConstructor):
2420
2421 2013-01-23  Kentaro Hara  <haraken@chromium.org>
2422
2423         [V8] Move V8DOMWrapper::getEventListener() to V8EventListerList
2424         https://bugs.webkit.org/show_bug.cgi?id=107683
2425
2426         Reviewed by Adam Barth.
2427
2428         No tests. No change in behavior.
2429
2430         * bindings/scripts/CodeGeneratorV8.pm:
2431         (GenerateNormalAttrSetter):
2432         (GenerateEventListenerCallback):
2433         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2434         (WebCore::TestEventTargetV8Internal::addEventListenerCallback):
2435         (WebCore::TestEventTargetV8Internal::removeEventListenerCallback):
2436         * bindings/scripts/test/V8/V8TestObj.cpp:
2437         (WebCore::TestObjV8Internal::addEventListenerCallback):
2438         (WebCore::TestObjV8Internal::removeEventListenerCallback):
2439         * bindings/v8/V8DOMWrapper.cpp:
2440         * bindings/v8/V8DOMWrapper.h:
2441         (V8DOMWrapper):
2442         * bindings/v8/V8EventListenerList.cpp:
2443         (WebCore::V8EventListenerList::getEventListener):
2444         (WebCore):
2445         * bindings/v8/V8EventListenerList.h:
2446         (WebCore):
2447         (V8EventListenerList):
2448         (WebCore::V8EventListenerList::findWrapper):
2449         (WebCore::V8EventListenerList::clearWrapper):
2450         (WebCore::V8EventListenerList::doFindWrapper):
2451         (WebCore::V8EventListenerList::getHiddenProperty):
2452         (WebCore::V8EventListenerList::findOrCreateWrapper):
2453         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2454         (WebCore::V8DOMWindow::addEventListenerCallback):
2455         (WebCore::V8DOMWindow::removeEventListenerCallback):
2456
2457 2013-01-23  Dominic Mazzoni  <dmazzoni@google.com>
2458
2459         AX: AXObjectCache should be initialized with topDocument
2460         https://bugs.webkit.org/show_bug.cgi?id=107638
2461
2462         Reviewed by Chris Fleizach.
2463
2464         Initialize AXObjectCache with the top document, not the
2465         document that axObjectCache happened to be called on, which
2466         could be an iframe. Having an AXObjectCache with the wrong
2467         document could cause a heap-use-after-free in
2468         notificationPostTimerFired if the inner document was deleted
2469         while notifications were pending.
2470
2471         * dom/Document.cpp:
2472         (WebCore::Document::axObjectCache):
2473
2474 2012-12-12  Ryosuke Niwa  <rniwa@webkit.org>
2475
2476         REGRESSION: WebKit does not render selection in non-first ruby text nodes.
2477         https://bugs.webkit.org/show_bug.cgi?id=92818
2478
2479         Reviewed by Levi Weintraub.
2480
2481         The patch is based on the one submitted by Sukolsak Sakshuwong.
2482
2483         The bug was caused by the fact isSelectionRoot was returning false on RenderRubyRun even though
2484         it doesn't lay down its children in block direction.
2485
2486         The selection painting code assumes that all blocks in each selection root are laid down in
2487         the containing block direction. In particular, InlineTextBox::paintSelection calls
2488         RootInlineBox::selectionTopAdjustedForPrecedingBlock in order to determine the end of the previous
2489         line, which in turn calls blockBeforeWithinSelectionRoot. blockBeforeWithinSelectionRoot goes
2490         through block nodes that appears before "this" block, and selectionTopAdjustedForPrecedingBlock
2491         assumes that to compute the end of the previous line.
2492
2493         Now suppose we have markup such as <ruby>Ichi<rt>One</rt></ruby><ruby>Ni<rt>Two</rt></ruby>. When
2494         selectionTopAdjustedForPrecedingBlock is called on the line box generated for "Two", it tries to
2495         determine the bottom of the inline box above that of "Two", which blockBeforeWithinSelectionRoot
2496         determines to be that of "One". At this point, everything goes wrong and the selection height is
2497         computed to be 0.
2498
2499         The fix to this problem is to allow RenderRubyRun to be a selection root. Since RenderRubyRun is
2500         already an inline-block, it suffices to bypass the !nonPseudoNode() check. In fact, there is no
2501         need to check this condition anymore as far as I can tell. The check was added in
2502         http://trac.webkit.org/changeset/12986 but all tests added by this change set as well as the rest
2503         of layout tests pass without this condition.
2504
2505         Test: fast/ruby/select-ruby.html
2506
2507         * rendering/RenderBlock.cpp:
2508         (WebCore::RenderBlock::isSelectionRoot):
2509
2510 2013-01-23  Kentaro Hara  <haraken@chromium.org>
2511
2512         [V8] Reduce usage of deprecatedV8String() and deprecatedV8Integer()
2513         https://bugs.webkit.org/show_bug.cgi?id=107674
2514
2515         Reviewed by Adam Barth.
2516
2517         No tests. No change in behavior.
2518
2519         * bindings/v8/JavaScriptCallFrame.cpp:
2520         (WebCore::JavaScriptCallFrame::evaluate):
2521         * bindings/v8/NPV8Object.cpp:
2522         (_NPN_Enumerate):
2523         * bindings/v8/PageScriptDebugServer.cpp:
2524         (WebCore::PageScriptDebugServer::addListener):
2525         * bindings/v8/ScriptController.cpp:
2526         (WebCore::ScriptController::bindToWindowObject):
2527         (WebCore::ScriptController::disableEval):
2528         * bindings/v8/ScriptDebugServer.cpp:
2529         (WebCore::ScriptDebugServer::setBreakpoint):
2530         (WebCore::ScriptDebugServer::removeBreakpoint):
2531         (WebCore::ScriptDebugServer::setScriptSource):
2532         (WebCore::ScriptDebugServer::ensureDebuggerScriptCompiled):
2533         (WebCore::ScriptDebugServer::compileScript):
2534         * bindings/v8/ScriptFunctionCall.cpp:
2535         (WebCore::ScriptCallArgumentHandler::appendArgument):
2536         (WebCore::ScriptFunctionCall::call):
2537         (WebCore::ScriptFunctionCall::construct):
2538         * bindings/v8/ScriptProfiler.cpp:
2539         (WebCore::ScriptProfiler::start):
2540         (WebCore::ScriptProfiler::stop):
2541         * bindings/v8/V8DOMWindowShell.cpp:
2542         (WebCore::V8DOMWindowShell::initializeIfNeeded):
2543         (WebCore::V8DOMWindowShell::namedItemAdded):
2544         (WebCore::V8DOMWindowShell::namedItemRemoved):
2545         * bindings/v8/V8LazyEventListener.cpp:
2546         (WebCore::V8LazyEventListener::prepareListenerObject):
2547         * bindings/v8/V8MutationCallback.cpp:
2548         (WebCore::V8MutationCallback::handleEvent):
2549         * bindings/v8/WorkerScriptController.cpp:
2550         (WebCore::WorkerScriptController::evaluate):
2551         * bindings/v8/WorkerScriptDebugServer.cpp:
2552         (WebCore::WorkerScriptDebugServer::addListener):
2553         * bindings/v8/custom/V8InjectedScriptManager.cpp:
2554         (WebCore::InjectedScriptManager::createInjectedScript):
2555
2556 2013-01-23  Martin Robinson  <mrobinson@igalia.com>
2557
2558         WebKit should support decoding multi-byte entities in XML content
2559         https://bugs.webkit.org/show_bug.cgi?id=107459
2560
2561         Reviewed by Adam Barth.
2562
2563         Test: fast/parser/entities-in-xhtml.xhtml
2564
2565         * html/parser/HTMLEntityParser.cpp:
2566         (WebCore::appendUChar32ToUCharArray): Added this helper function. Later patches
2567         may try to move this code to somewhere that it can be shared more easily.
2568         (WebCore::decodeNamedEntityToUCharArray): Modify this function to work on a UChar
2569         array four elements long, so that multi-byte and multi-character entities can be resolved.
2570         * html/parser/HTMLEntityParser.h: Updated function declaratoin.
2571         * xml/parser/XMLDocumentParserLibxml2.cpp:
2572         (WebCore): Modify the statically allocated entity string memory area to accommodate
2573         up to two UTF-8 characters. Each UTF-8 character can be 4 bytes, so this brings the
2574         total size to 9 bytes.
2575         (WebCore::getXHTMLEntity): Use the new entity decoding API.
2576         * xml/parser/XMLDocumentParserQt.cpp:
2577         (WebCore::EntityResolver::resolveUndeclaredEntity): Ditto.
2578         (WebCore::XMLDocumentParser::parse): Ditto.
2579
2580 2013-01-23  Eric Seidel  <eric@webkit.org>
2581
2582         Stop the background-parser during HTMLDocumentParser::detatch to prevent crashes/asserts
2583         https://bugs.webkit.org/show_bug.cgi?id=107751
2584
2585         Reviewed by Tony Gentilcore.
2586
2587         This appears to fix the 2 intermitent crashers we were seeing while
2588         running fast/parser.  And definitely fixes 8 ASSERTs seen using a Debug build.
2589
2590         * html/parser/HTMLDocumentParser.cpp:
2591         (WebCore::HTMLDocumentParser::detach):
2592
2593 2013-01-23  Hans Muller  <hmuller@adobe.com>
2594
2595         [CSS Exclusions] Add support for computing first included interval position for polygons
2596         https://bugs.webkit.org/show_bug.cgi?id=103429
2597
2598         Reviewed by Dirk Schulze.
2599
2600         Added support for computing the "first fit" location, i.e. the logical shape-inside
2601         location where a line's layout begins. The algorithm for doing so is described here:
2602         http://hansmuller-webkit.blogspot.com/2012/08/revised-algorithm-for-finding-first.html.
2603
2604         Tests: fast/exclusions/shape-inside/shape-inside-first-fit-001.html
2605                fast/exclusions/shape-inside/shape-inside-first-fit-002.html
2606                fast/exclusions/shape-inside/shape-inside-first-fit-003.html
2607
2608         * platform/graphics/FloatSize.h:
2609         (WebCore::operator*): Scale a FloatSize. This simplified the final expression in VertexPair::intersection().
2610         * rendering/ExclusionPolygon.cpp:
2611         (WebCore::isPointOnLineSegment): Returns true if the specified point is collinear and within the line segement's bounds.
2612         (WebCore::leftSide): Return a value > 0 if point is on the left side of the line segment, < 0 if it's on the right, 0 if it's collinear.
2613         (WebCore::ExclusionPolygon::contains): Return true if the point is within the polygon or on an edge.
2614         (WebCore::VertexPair::overlapsRect): Returns true if the line segment from vertex1 to vertex2 overlaps the specified FloatRect.
2615         (WebCore::VertexPair::intersection): Finds the intersection of a pair of line segments defined by VertexPairs.
2616         (WebCore::ExclusionPolygon::firstFitRectInPolygon): Returns true if none of the polygon's edges, except the two used
2617             to define by the offset edges, overlap the FloatRect.
2618         (WebCore::aboveOrToTheLeft): Defines the top/left preference for "first fit" locations.
2619         (WebCore::ExclusionPolygon::firstIncludedIntervalLogicalTop): Replaced the stub implementation of this method.
2620         * rendering/ExclusionPolygon.h:
2621         (ExclusionPolygon): Added declarations noted above.
2622         (VertexPair): Abstract class that defines a pair of FloatPoints.
2623         (OffsetPolygonEdge): Represents an edge that's horizontally offset from a polygon edge.
2624         (WebCore::OffsetPolygonEdge::edgeIndex): The ExclusionPolygon edge index used to define this OffsetEdge.
2625
2626 2013-01-23  Dirk Schulze  <dschulze@adobe.com>
2627
2628         Implement Canvas Path object
2629         https://bugs.webkit.org/show_bug.cgi?id=97333
2630
2631         Reviewed by Dean Jackson.
2632
2633         The Canvas part of the WHATWG specification defines a Path object. This Path object
2634         shares several path segment functions (path methods) with the CanvasRenderingContext2D
2635         interface. This patch introduces the Path object and shares the path segment functions
2636         in the class CanvasPathMethods.
2637         This patch does just implement the basic path functions that have a general agreement on
2638         the WHAT WG and W3C mailing lists.
2639         This feature is behind a flag and won't be activated by default.
2640
2641         http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#path-objects
2642
2643         Test: fast/canvas/canvas-path-object.html
2644
2645         * CMakeLists.txt: Add DOMPath and CanvasPathMedthods to build system.
2646         * DerivedSources.cpp: Ditto.
2647         * DerivedSources.make: Ditto.
2648         * DerivedSources.pri: Ditto.
2649         * GNUmakefile.list.am: Ditto.
2650         * Target.pri: Ditto.
2651         * WebCore.gypi: Ditto.
2652         * WebCore.vcproj/WebCore.vcproj: Ditto.
2653         * WebCore.xcodeproj/project.pbxproj: Ditto.
2654         * html/canvas/CanvasPathMethods.cpp: Added.
2655         (WebCore): This class shares the path segment functions (moveTo, lineTo, ...) between
2656             DOMPath (the Path object) and CanvasRenderingContext2D.
2657         (WebCore::CanvasPathMethods::closePath):
2658         (WebCore::CanvasPathMethods::moveTo):
2659         (WebCore::CanvasPathMethods::lineTo):
2660         (WebCore::CanvasPathMethods::quadraticCurveTo):
2661         (WebCore::CanvasPathMethods::bezierCurveTo):
2662         (WebCore::CanvasPathMethods::arcTo):
2663         (WebCore::CanvasPathMethods::arc):
2664         (WebCore::CanvasPathMethods::rect):
2665         * html/canvas/CanvasPathMethods.h: Added.
2666         (WebCore):
2667         (CanvasPathMethods):
2668         (WebCore::CanvasPathMethods::~CanvasPathMethods):
2669         (WebCore::CanvasPathMethods::transformIsInvertible):
2670         (WebCore::CanvasPathMethods::CanvasPathMethods):
2671         * html/canvas/CanvasRenderingContext2D.cpp:
2672         * html/canvas/CanvasRenderingContext2D.h: Remove the path segment functions here.
2673         (CanvasRenderingContext2D):
2674         (WebCore::CanvasRenderingContext2D::transformIsInvertible): This checks if the CTM
2675             of the context is still invertible. Drawing should stop if it is not.
2676         * html/canvas/CanvasRenderingContext2D.idl:
2677         * html/canvas/DOMPath.h: Added.
2678         (WebCore):
2679         (DOMPath):
2680         (WebCore::DOMPath::create):
2681         (WebCore::DOMPath::~DOMPath):
2682         (WebCore::DOMPath::DOMPath):
2683         * html/canvas/DOMPath.idl: Added.
2684         * page/DOMWindow.idl: Added CTOR for Path.
2685
2686 2013-01-23  Joshua Bell  <jsbell@chromium.org>
2687
2688         IndexedDB: Remove IDBVersionChangeRequest
2689         https://bugs.webkit.org/show_bug.cgi?id=107711
2690
2691         Reviewed by Tony Chang.
2692
2693         When the setVersion() API was removed from the Indexed DB spec the IDBVersionChangeRequest
2694         interface was replaced with IDBOpenDBRequest. We switched over for open(), this completes
2695         the work by switching over for deleteDatabase() and removing the old code. (On the Event
2696         side we still need to combine IDBVersionChangeEvent and IDBUpgradeNeededEvent.)
2697
2698         Test: storage/indexeddb/intversion-long-queue.html
2699               storage/indexeddb/intversion-upgrades.html
2700
2701         * CMakeLists.txt: Remove references to deleted code.
2702         * DerivedSources.make: Ditto.
2703         * GNUmakefile.list.am: Ditto.
2704         * Modules/indexeddb/IDBCallbacks.h: Remove unused onBlocked() overload.
2705         * Modules/indexeddb/IDBDatabase.cpp: Remove references to deleted code.
2706         * Modules/indexeddb/IDBDatabase.h: Ditto.
2707         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
2708         (WebCore::IDBDatabaseBackendImpl::deleteDatabase): Fire onBlocked with current version.
2709         * Modules/indexeddb/IDBFactory.cpp:
2710         (WebCore::IDBFactory::openInternal): Don't need to specify source.
2711         (WebCore::IDBFactory::deleteDatabase): Use an IDBOpenDBRequest.
2712         * Modules/indexeddb/IDBFactory.h: Change return type of deleteDatabase()
2713         * Modules/indexeddb/IDBFactory.idl: Ditto.
2714         * Modules/indexeddb/IDBOpenDBRequest.cpp:
2715         (WebCore::IDBOpenDBRequest::create): Always use a null source.
2716         (WebCore::IDBOpenDBRequest::IDBOpenDBRequest): Pass null source to base class.
2717         (WebCore::IDBOpenDBRequest::dispatchEvent): Don't assume result is a database in existing
2718         special case.
2719         * Modules/indexeddb/IDBOpenDBRequest.h: Don't need a source argument (always null).
2720         * Modules/indexeddb/IDBVersionChangeRequest.cpp: Removed.
2721         * Modules/indexeddb/IDBVersionChangeRequest.h: Removed.
2722         * Modules/indexeddb/IDBVersionChangeRequest.idl: Removed.
2723         * WebCore.gypi: Remove references to deleted code.
2724         * WebCore.xcodeproj/project.pbxproj: Remove references to deleted code.
2725         * dom/EventTarget.h: Remove references to deleted code.
2726         * dom/EventTargetFactory.in: Ditto.
2727
2728 2013-01-23  Scott Graham  <scottmg@chromium.org>
2729
2730         [Chromium] Fix inclusion of pch .cpp in webcore_platform and webcore_rendering
2731         https://bugs.webkit.org/show_bug.cgi?id=107700
2732
2733         Reviewed by Dirk Pranke.
2734
2735         No new tests, Chromium should link on VS 2012.
2736
2737         * WebCore.gyp/WebCore.gyp:
2738
2739 2013-01-23  Jun Jiang  <jun.a.jiang@intel.com>
2740
2741         Avoid unnecessary format conversion for tex{Sub}Image2D() for ImageData of WebGL
2742         https://bugs.webkit.org/show_bug.cgi?id=107532
2743
2744         Reviewed by Kenneth Russell.
2745
2746         This patch removes the unnecessary format conversion in tex{Sub}Image2D() for ImageData in WebGL to improve performance.
2747
2748         Already covered by current tests.
2749
2750         * html/canvas/WebGLRenderingContext.cpp:
2751         (WebCore):
2752         (WebCore::WebGLRenderingContext::texImage2D):
2753         (WebCore::WebGLRenderingContext::texSubImage2D):
2754
2755 2013-01-23  Xianzhu Wang  <wangxianzhu@chromium.org>
2756
2757         Should update compositing state when an out-of-view fixed position element becomes in-view
2758         https://bugs.webkit.org/show_bug.cgi?id=107410
2759
2760         Reviewed by Simon Fraser.
2761
2762         When a non-compositing page contains some not-composited fixed position element because of bounds out-of-view, when the element changes position and RenderLayerCompositor::updateCompositingLayers() is called, the function may return early because of "if (!m_reevaluateCompositingAfterLayout && !m_compositing)" without updating the compositing layers.
2763
2764         Set m_reevaluateCompositingAfterLayout when a fixed position element is not composited because of bounds out-of-view.
2765
2766         Test: compositing/layer-creation/fixed-position-change-out-of-view-in-view.html
2767
2768         * rendering/RenderLayerCompositor.cpp:
2769         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2770
2771 2013-01-23  Tony Chang  <tony@chromium.org>
2772
2773         Unreviewed, set svn:eol-style to CRLF on Windows .sln files.
2774
2775         * WebCore.vcproj/WebCore.sln: Modified property svn:eol-style.
2776         * WebCore.vcproj/WebCore.submit.sln: Modified property svn:eol-style.
2777
2778 2013-01-23  Adam Barth  <abarth@webkit.org>
2779
2780         BackgroundHTMLParser::sendTokensToMainThread should use bind
2781         https://bugs.webkit.org/show_bug.cgi?id=107637
2782
2783         Reviewed by Eric Seidel.
2784
2785         This patch replaces our hand-written implementation of bind for
2786         didReceiveTokensFromBackgroundParser with bind from Functional.h. To
2787         use the generic version of bind, we need to switch to using WeakPtr to
2788         hold a reference to the main thread parser in the BackgroundHTMLParser.
2789
2790         * html/parser/BackgroundHTMLParser.cpp:
2791         (WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
2792         (WebCore::BackgroundHTMLParser::sendTokensToMainThread):
2793         (WebCore::BackgroundHTMLParser::createPartial):
2794         * html/parser/BackgroundHTMLParser.h:
2795         (WebCore::BackgroundHTMLParser::create):
2796         (BackgroundHTMLParser):
2797         (ParserMap):
2798         * html/parser/HTMLDocumentParser.cpp:
2799         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
2800         (WebCore::HTMLDocumentParser::startBackgroundParser):
2801         (WebCore::HTMLDocumentParser::stopBackgroundParser):
2802         * html/parser/HTMLDocumentParser.h:
2803         (HTMLDocumentParser):
2804
2805 2013-01-23  Roger Fong  <roger_fong@apple.com>
2806
2807         Unreviewed. Cleanup VS2010 WebCore project. 
2808         Lots of files that no longer exist in solution.
2809
2810         * WebCore.vcxproj/WebCore.vcxproj:
2811         * WebCore.vcxproj/WebCore.vcxproj.filters:
2812
2813 2013-01-23  Julien Chaffraix  <jchaffraix@webkit.org>
2814
2815         [CSS Grid Layout] Add support for max-content
2816         https://bugs.webkit.org/show_bug.cgi?id=107604
2817
2818         Reviewed by Tony Chang.
2819
2820         Tests: fast/css-grid-layout/minmax-max-content-resolution-columns.html
2821                fast/css-grid-layout/minmax-max-content-resolution-rows.html
2822
2823         This change implements max-content on top of the infrastructure introduced as part
2824         of implementing min-content (bug 106474). No effort was made to share code, which
2825         is what was done for min-content. The sharing will occur in follow-up refactoring(s)
2826         to benefit from the extra testing but also the extra code to make the direction more
2827         obvious.
2828
2829         * rendering/RenderGrid.cpp:
2830         (WebCore::RenderGrid::maxContentForChild):
2831         Added this helper, similar to minContentForChild.
2832
2833         (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctions):
2834         Patched the function to handle max-content per the specification's algorithm.
2835
2836         * rendering/RenderGrid.h:
2837         Added maxContentForChild.
2838
2839 2013-01-23  Mark Lam  <mark.lam@apple.com>
2840
2841         Assert that Supplementable objects is only used in their creator thread.
2842         https://bugs.webkit.org/show_bug.cgi?id=107717.
2843
2844         Reviewed by Adam Barth.
2845
2846         No new tests.
2847
2848         * platform/Supplementable.h:
2849         (WebCore):
2850         (WebCore::Supplementable::provideSupplement):
2851         (WebCore::Supplementable::removeSupplement):
2852         (WebCore::Supplementable::requireSupplement):
2853         (Supplementable):
2854         (WebCore::Supplementable::Supplementable):
2855
2856 2013-01-23  Tony Chang  <tony@chromium.org>
2857
2858         Incorrect scrollable height during simplified layout
2859         https://bugs.webkit.org/show_bug.cgi?id=107193
2860
2861         Reviewed by David Hyatt.
2862
2863         When computing overflow we need the height of the block before
2864         it was clamped (i.e., before updateLogicalHeight() has been called).
2865
2866         During simplified layout, we don't have this information and we were
2867         using the clamped height by mistake. To fix this, we now store the
2868         pre-clamped height on RenderOverflow so we can properly compute
2869         overflow.
2870
2871         Test: fast/overflow/height-during-simplified-layout.html
2872
2873         * rendering/RenderBlock.cpp:
2874         (WebCore::RenderBlock::computeOverflow): Save the height if we have overflow.
2875         (WebCore::RenderBlock::simplifiedLayout): If we have overflow, use the height that we saved
2876         in computeOverflow.
2877         * rendering/RenderOverflow.h:
2878         (WebCore::RenderOverflow::layoutClientAfterEdge):
2879         (WebCore::RenderOverflow::setLayoutClientAfterEdge):
2880         (RenderOverflow): Add a member variable to save the height.
2881
2882 2013-01-23  Tom Sepez  <tsepez@chromium.org>
2883
2884         [chromium] harden ScriptWrappable::m_wrapper against tampering
2885         https://bugs.webkit.org/show_bug.cgi?id=107318
2886
2887         Reviewed by Adam Barth.
2888
2889         Patch is correct if existing tests past without crashing.
2890
2891         * bindings/v8/ScriptWrappable.h:
2892         (WebCore::ScriptWrappable::ScriptWrappable):
2893         (WebCore::ScriptWrappable::wrapper):
2894         (WebCore::ScriptWrappable::setWrapper):
2895         (WebCore::ScriptWrappable::clearWrapper):
2896         (WebCore::ScriptWrappable::disposeWrapper):
2897         (WebCore::ScriptWrappable::reportMemoryUsage):
2898         (ScriptWrappable):
2899         (WebCore::ScriptWrappable::maskOrUnmaskPointer):
2900
2901 2013-01-22  Roger Fong  <roger_fong@apple.com>
2902
2903         WebCore property sheets, modified build scripts, and project files for compiling in VS2010.
2904         https://bugs.webkit.org/show_bug.cgi?id=106988
2905
2906         Reviewed by Brent Fulgham.
2907
2908         * WebCore.vcproj/WebCore.sln:
2909         * WebCore.vcxproj: Added.
2910         * WebCore.vcxproj/MigrateScripts: Added.
2911         * WebCore.vcxproj/QTMovieWin: Added.
2912         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj: Added.
2913         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj.filters: Added.
2914         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj.user: Added.
2915         * WebCore.vcxproj/QTMovieWin/QTMovieWinCommon.props: Added.
2916         * WebCore.vcxproj/QTMovieWin/QTMovieWinDebug.props: Added.
2917         * WebCore.vcxproj/QTMovieWin/QTMovieWinRelease.props: Added.
2918         * WebCore.vcxproj/WebCore.vcxproj: Added.
2919         * WebCore.vcxproj/WebCore.vcxproj.filters: Added.
2920         * WebCore.vcxproj/WebCore.vcxproj.user: Added.
2921         * WebCore.vcxproj/WebCoreCFNetwork.props: Added.
2922         * WebCore.vcxproj/WebCoreCG.props: Added.
2923         * WebCore.vcxproj/WebCoreCommon.props: Added.
2924         * WebCore.vcxproj/WebCoreDebug.props: Added.
2925         * WebCore.vcxproj/WebCoreGenerated.make: Added.
2926         * WebCore.vcxproj/WebCoreGenerated.vcxproj: Added.
2927         * WebCore.vcxproj/WebCoreGenerated.vcxproj.filters: Added.
2928         * WebCore.vcxproj/WebCoreGenerated.vcxproj.user: Added.
2929         * WebCore.vcxproj/WebCoreGeneratedCommon.props: Added.
2930         * WebCore.vcxproj/WebCoreGeneratedDebug.props: Added.
2931         * WebCore.vcxproj/WebCoreGeneratedRelease.props: Added.
2932         * WebCore.vcxproj/WebCoreMediaQT.props: Added.
2933         * WebCore.vcxproj/WebCorePostBuild.cmd: Added.
2934         * WebCore.vcxproj/WebCorePreBuild.cmd: Added.
2935         * WebCore.vcxproj/WebCorePreLink.cmd: Added.
2936         * WebCore.vcxproj/WebCorePthreads.props: Added.
2937         * WebCore.vcxproj/WebCoreQuartzCore.props: Added.
2938         * WebCore.vcxproj/WebCoreRelease.props: Added.
2939         * WebCore.vcxproj/build-generated-files.sh: Added.
2940         * WebCore.vcxproj/copyForwardingHeaders.cmd: Added.
2941         * WebCore.vcxproj/copyWebCoreResourceFiles.cmd: Added.
2942         * WebCore.vcxproj/migrate-scripts.sh: Added.
2943         * WebCore.vcxproj/xcopy.excludes: Added.
2944         * WebCorePrefix.h:
2945         * config.h:
2946
2947 2013-01-23  Eric Seidel  <eric@webkit.org>
2948
2949         HTMLCompactToken needs to include the forceQuirks bool from HTMLToken
2950         https://bugs.webkit.org/show_bug.cgi?id=107713
2951
2952         Reviewed by Tony Gentilcore.
2953
2954         Before we were only getting "quirks mode" when the system/public identifiers
2955         were known quirks identifiers.  Now we'll correctly get quirks mode for any
2956         parse error during DOCTYPE parsing.
2957         This passes a bunch more tests.
2958
2959         * html/parser/CompactHTMLToken.cpp:
2960         (WebCore::CompactHTMLToken::CompactHTMLToken):
2961         * html/parser/CompactHTMLToken.h:
2962         (WebCore::CompactHTMLToken::doctypeForcesQuirks):
2963         (CompactHTMLToken):
2964         * html/parser/HTMLToken.h:
2965         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
2966
2967 2013-01-23  Brady Eidson  <beidson@apple.com>
2968
2969         Recursion handling cancelled authentication challenges in NetworkProcess
2970         <rdar://problem/13024541> and https://bugs.webkit.org/show_bug.cgi?id=107702
2971
2972         Reviewed by Alexey Proskuryakov.
2973
2974         * WebCore.exp.in:
2975
2976 2013-01-23  Beth Dakin  <bdakin@apple.com>
2977
2978         https://bugs.webkit.org/show_bug.cgi?id=107628
2979         Sometimes scroll position is jerky during rubber-band, affects nytimes.com
2980         -and corresponding-
2981         <rdar://problem/12679549>
2982
2983         Reviewed by Simon Fraser.
2984
2985         The basic problem here is that isRubberBandInProgress() was only implemented for 
2986         main thread scrolling. So when we were actually scrolling on the scrolling thread, 
2987         that function would always return false regardless.
2988
2989         New ScrollableArea virtual function isRubberBandInProgress() will allow us to ask 
2990         the ScrollingCoordinator when the scrolling thread is scrolling, or the 
2991         ScrollAnimator otherwise.
2992         * page/FrameView.cpp:
2993         (WebCore::FrameView::isRubberBandInProgress):
2994         * page/FrameView.h:
2995         (FrameView):
2996         * platform/ScrollableArea.h:
2997         (WebCore::ScrollableArea::isRubberBandInProgress):
2998
2999         New ScrollingCoordinator function isRubberBandInProgress() always returns false 
3000         for non-Mac ports, and is overridden in ScrollingCoordinatorMac to consult the 
3001         ScrollingTree.
3002         * page/scrolling/ScrollingCoordinator.h:
3003         (WebCore::ScrollingCoordinator::isRubberBandInProgress):
3004         * page/scrolling/mac/ScrollingCoordinatorMac.h:
3005         (ScrollingCoordinatorMac):
3006         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
3007         (WebCore::ScrollingCoordinatorMac::isRubberBandInProgress):
3008
3009         New variable m_mainFrameIsRubberBanding keeps track of whether there is currently 
3010         a rubber-band happening on the scrolling thread.
3011         * page/scrolling/ScrollingTree.cpp:
3012         (WebCore::ScrollingTree::ScrollingTree):
3013         (WebCore::ScrollingTree::isRubberBandInProgress):
3014         (WebCore::ScrollingTree::setMainFrameIsRubberBanding):
3015         * page/scrolling/ScrollingTree.h:
3016         (ScrollingTree):
3017         (WebCore::ScrollingTree::rootNode):
3018
3019         Call setMainFrameIsRubberBanding() whenever the stretchAmount is calculated and 
3020         whenever we stop the rubber-band timer.
3021         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
3022         (WebCore::ScrollingTreeScrollingNodeMac::stretchAmount):
3023         (WebCore::ScrollingTreeScrollingNodeMac::stopSnapRubberbandTimer):
3024
3025         Consult FrameView for isRubberBandInProgress().
3026         * platform/ScrollView.cpp:
3027         (WebCore::ScrollView::updateScrollbars):
3028
3029 2013-01-23  Robert Hogan  <robert@webkit.org>
3030
3031         Abspos Inline block not positioned correctly in text-aligned container
3032         https://bugs.webkit.org/show_bug.cgi?id=105695
3033
3034         Reviewed by Ojan Vafai.
3035
3036         Inline positioned elements should still obey the text-alignment of their container
3037         even when we don't do a line layout.
3038
3039         Test: fast/text/container-align-with-inlines.html
3040
3041         * rendering/RenderBlock.cpp:
3042         (WebCore::RenderBlock::adjustPositionedBlock):
3043         (WebCore::RenderBlock::updateStaticInlinePositionForChild):
3044         (WebCore):
3045         * rendering/RenderBlock.h:
3046         (RenderBlock):
3047         * rendering/RenderBlockLineLayout.cpp:
3048         (WebCore::setStaticPositions):
3049
3050 2013-01-23  Eric Seidel  <eric@webkit.org>
3051
3052         Remove DocType support from MarkupTokenBase now that NEW_XML is gone
3053         https://bugs.webkit.org/show_bug.cgi?id=107709
3054
3055         Reviewed by Adam Barth.
3056
3057         Just moving code out of MarkupTokenBase and into HTMLToken.
3058         The test for this change is if it compiles. :)  Which it does.
3059
3060         * html/parser/HTMLToken.h:
3061         (DoctypeData):
3062         (WebCore::DoctypeData::DoctypeData):
3063         (WebCore):
3064         (WebCore::HTMLToken::appendToName):
3065         (WebCore::HTMLToken::name):
3066         (HTMLToken):
3067         (WebCore::HTMLToken::beginDOCTYPE):
3068         (WebCore::HTMLToken::publicIdentifier):
3069         (WebCore::HTMLToken::systemIdentifier):
3070         (WebCore::HTMLToken::setPublicIdentifierToEmptyString):
3071         (WebCore::HTMLToken::setSystemIdentifierToEmptyString):
3072         (WebCore::HTMLToken::appendToPublicIdentifier):
3073         (WebCore::HTMLToken::appendToSystemIdentifier):
3074         (WebCore::HTMLToken::releaseDoctypeData):
3075         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
3076         (AtomicHTMLToken):
3077         * html/parser/HTMLTokenTypes.h:
3078         * xml/parser/MarkupTokenBase.h:
3079         (WebCore):
3080         (MarkupTokenBase):
3081
3082 2013-01-23  Alexis Menard  <alexis@webkit.org>
3083
3084         transition-property accepts incorrect "all, none" as value
3085         https://bugs.webkit.org/show_bug.cgi?id=105428
3086
3087         Reviewed by Dean Jackson.
3088
3089         http://www.w3.org/TR/css3-transitions/#transition-property-property
3090         disallows any value like none, all or all, none as it doesn't make
3091         sense. This patch fixes the problem by rejecting the value if set by
3092         the user.
3093
3094         Test: transitions/transitions-parsing.html
3095
3096         * css/CSSParser.cpp:
3097         (WebCore::CSSParser::parseAnimationProperty):
3098         * css/CSSParser.h:
3099
3100 2013-01-23  Eric Seidel  <eric@webkit.org>
3101
3102         Clarify some usage of shouldUseThreading vs m_haveBackgroundParser, fixing about:blank parsing
3103         https://bugs.webkit.org/show_bug.cgi?id=107664
3104
3105         Reviewed by Adam Barth.
3106
3107         The HTMLDocumentParser can be "supposed" to use a background parser
3108         but not end up ever doing so for blank documents.  It's important
3109         that we spin the forground parser at least once, so we end up
3110         actually creating the about:blank document.
3111
3112         shouldUseThreading() means that threading is enabled and we should use it if we can.
3113         m_haveBackgroundParser means that we actually are already using threading.
3114         When we add full document.write support this will get a bit trickier still as
3115         we'll need to be using both the foreground and background parsers.
3116
3117         This fixes about 20 tests in fast/frames and many others outside of fast/frames. :)
3118
3119         * html/parser/HTMLDocumentParser.cpp:
3120         (WebCore::HTMLDocumentParser::prepareToStopParsing):
3121         (WebCore::HTMLDocumentParser::resumeParsingAfterYield):
3122         (WebCore::HTMLDocumentParser::finish):
3123         (WebCore::HTMLDocumentParser::lineNumber):
3124         (WebCore::HTMLDocumentParser::textPosition):
3125
3126 2013-01-17  Roger Fong  <roger_fong@apple.com>
3127
3128         [Win] Remove dependence on Microsoft Embedded OpenType Font Engine (T2EMBED.DLL)  from FontCustomPlatformData.cpp.
3129         https://bugs.webkit.org/show_bug.cgi?id=107153
3130
3131         Reviewed by Dan Bernstein.
3132
3133         * platform/graphics/win/FontCustomPlatformData.cpp:
3134         (WebCore):
3135         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
3136         (WebCore::FontCustomPlatformData::fontPlatformData):
3137         (WebCore::createFontCustomPlatformData):
3138
3139 2013-01-23  Andrey Lushnikov  <lushnikov@chromium.org>
3140
3141         Web Inspector: speedup highlight regex API in DefaultTextEditor
3142         https://bugs.webkit.org/show_bug.cgi?id=107238
3143
3144         Reviewed by Pavel Feldman.
3145
3146         Move overlay highlight measurement (highlight regex API) from DefaultTextEditor._paintLine
3147         method to the DefaultTextEditor._paintLines method which allows to relayout dom only
3148         once. This is a significant improvement to the current state of the
3149         art which does relayout on each regex occurence.
3150         In addition, use "left" css attribute instead of "margin-left": this
3151         way it will be possible to avoid an unnecessary relayouting during
3152         appending overlay highlight.
3153
3154         No new tests: no change in behaviour.
3155
3156         * inspector/front-end/DefaultTextEditor.js:
3157         (WebInspector.TextEditorMainPanel.prototype.markAndRevealRange):
3158         (WebInspector.TextEditorMainPanel.prototype._paintLines):
3159         (WebInspector.TextEditorMainPanel.prototype._measureRegexHighlight):
3160         (WebInspector.TextEditorMainPanel.prototype._measureSpans):
3161         (WebInspector.TextEditorMainPanel.prototype._appendOverlayHighlight):
3162         (WebInspector.TextEditorMainPanel.prototype._paintLine):
3163         (WebInspector.TextEditorMainPanel.ElementMetrics):
3164         (WebInspector.TextEditorMainPanel.LineOverlayHighlight):
3165         (WebInspector.TextEditorMainChunk.prototype.expand):
3166
3167 2013-01-23  Ojan Vafai  <ojan@chromium.org>
3168
3169         Assert that computePreferredLogicalWidths never calls setNeedsLayout
3170         https://bugs.webkit.org/show_bug.cgi?id=107613
3171
3172         Reviewed by Eric Seidel.
3173
3174         computePreferredLogicalWidths should only set m_minPreferredLogicalWidth
3175         and m_maxPreferredLogicalWidth. It shouldn't have other side-effects.
3176         The mathml bits can be removed once https://bugs.webkit.org/show_bug.cgi?id=107353
3177         is resolved.
3178
3179         * rendering/RenderBox.cpp:
3180         (WebCore::RenderBox::minPreferredLogicalWidth):
3181         * rendering/mathml/RenderMathMLOperator.cpp:
3182         (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
3183         * rendering/mathml/RenderMathMLRoot.cpp:
3184         (WebCore::RenderMathMLRoot::computePreferredLogicalWidths):
3185         * rendering/mathml/RenderMathMLRow.cpp:
3186         (WebCore::RenderMathMLRow::computePreferredLogicalWidths):
3187
3188 2013-01-23  Noam Rosenthal  <noam@webkit.org>
3189
3190         REGRESSION(r140518): Broke Chromium Win build (gyp file not updated) (Requested by arv on #webkit).
3191         https://bugs.webkit.org/show_bug.cgi?id=107691
3192
3193         Unreviewed build fix. Removed TextureMapperShaderManager.* from WebCore.gypi.
3194
3195         * WebCore.gypi:
3196
3197 2013-01-23  Sheriff Bot  <webkit.review.bot@gmail.com>
3198
3199         Unreviewed, rolling out r140307, r140411, and r140512.
3200         http://trac.webkit.org/changeset/140307
3201         http://trac.webkit.org/changeset/140411
3202         http://trac.webkit.org/changeset/140512
3203         https://bugs.webkit.org/show_bug.cgi?id=107689
3204
3205         Perf regression on DOMDivWalk (bug 106726) (Requested by
3206         falken on #webkit).
3207
3208         * dom/Element.cpp:
3209         (WebCore::Element::removedFrom):
3210         (WebCore):
3211         (WebCore::Element::isInTopLayer):
3212         (WebCore::Element::setIsInTopLayer):
3213         * dom/Element.h:
3214         * dom/ElementRareData.h:
3215         (ElementRareData):
3216         (WebCore::ElementRareData::isInTopLayer):
3217         (WebCore::ElementRareData::setIsInTopLayer):
3218         (WebCore::ElementRareData::ElementRareData):
3219         * dom/Node.cpp:
3220         * dom/Node.h:
3221         (Node):
3222         * dom/NodeRenderingContext.cpp:
3223         (WebCore::isRendererReparented):
3224         (WebCore::NodeRenderingContext::previousRenderer):
3225         (WebCore::NodeRenderingContext::parentRenderer):
3226         * rendering/RenderLayer.cpp:
3227         (WebCore::RenderLayer::isInTopLayer):
3228         (WebCore::RenderLayer::rebuildZOrderLists):
3229
3230 2013-01-23  Dmitry Gozman  <dgozman@chromium.org>
3231
3232         Web Inspector: allow user to resize inspector window by dragging the toolbar
3233         https://bugs.webkit.org/show_bug.cgi?id=107648
3234
3235         Reviewed by Pavel Feldman.
3236
3237         This did not work before you click dock button once.
3238         Also, last drag position was not respected.
3239
3240         No new tests, because of pure inspector UI change.
3241
3242         * inspector/front-end/DockController.js:
3243         (WebInspector.DockController.prototype.isDockedToBottom):
3244         * inspector/front-end/Toolbar.js:
3245         (WebInspector.Toolbar.prototype._isDockedToBottom):
3246         (WebInspector.Toolbar.prototype._toolbarDragStart):
3247         (WebInspector.Toolbar.prototype._toolbarDragEnd):
3248         (WebInspector.Toolbar.prototype._toolbarDrag):
3249
3250 2013-01-23  Shinya Kawanaka  <shinyak@chromium.org>
3251
3252         shadowAncestorNode() should be renamed to deprecatedShadowAncestorNode()
3253         https://bugs.webkit.org/show_bug.cgi?id=107624
3254
3255         Reviewed by Dimitri Glazkov.
3256
3257         Since Node::shadowAncestorNode() is deprecated, we would like to rename it to prevent from further use.
3258
3259         No new tests, simple refactoring.
3260
3261         * WebCore.order:
3262         * accessibility/AccessibilityRenderObject.cpp:
3263         (WebCore::AccessibilityRenderObject::accessibilityHitTest):
3264         * dom/Document.cpp:
3265         (WebCore::Document::handleZeroPadding):
3266         * dom/Node.cpp:
3267         (WebCore::Node::deprecatedShadowAncestorNode):
3268         * dom/Node.h:
3269         (Node):
3270         * editing/Editor.cpp:
3271         (WebCore::Editor::rangeOfString):
3272         (WebCore::Editor::countMatchesForText):
3273         * editing/ReplaceSelectionCommand.cpp:
3274         (WebCore::ReplacementFragment::ReplacementFragment):
3275         * page/DragController.cpp:
3276         (WebCore::elementUnderMouse):
3277         * page/EventHandler.cpp:
3278         (WebCore::EventHandler::handleMouseReleaseEvent):
3279         (WebCore::EventHandler::bestClickableNodeForTouchPoint):
3280         * page/FocusController.cpp:
3281         (WebCore::clearSelectionIfNeeded):
3282         * platform/blackberry/RenderThemeBlackBerry.cpp:
3283         (WebCore::RenderThemeBlackBerry::paintSearchFieldCancelButton):
3284         * rendering/HitTestResult.cpp:
3285         (WebCore::HitTestResult::setToNonShadowAncestor):
3286         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
3287
3288 2013-01-22  Pavel Feldman  <pfeldman@chromium.org>
3289
3290         Web Inspector: only allow evaluateForTestInFrontend for front-ends under test.
3291         https://bugs.webkit.org/show_bug.cgi?id=107523
3292
3293         Reviewed by Yury Semikhatsky.
3294
3295         * inspector/InspectorController.cpp:
3296         (WebCore::InspectorController::InspectorController):
3297         (WebCore::InspectorController::isUnderTest):
3298         (WebCore):
3299         (WebCore::InspectorController::evaluateForTestInFrontend):
3300         * inspector/InspectorController.h:
3301         (InspectorController):
3302         * inspector/InspectorFrontendClient.h:
3303         (InspectorFrontendClient):
3304         * inspector/InspectorFrontendClientLocal.cpp:
3305         (WebCore::InspectorFrontendClientLocal::canAttachWindow):
3306         (WebCore::InspectorFrontendClientLocal::isUnderTest):
3307         (WebCore):
3308         * inspector/InspectorFrontendClientLocal.h:
3309         (InspectorFrontendClientLocal):
3310         * inspector/InspectorFrontendHost.cpp:
3311         (WebCore::InspectorFrontendHost::isUnderTest):
3312         (WebCore):
3313         * inspector/InspectorFrontendHost.h:
3314         (InspectorFrontendHost):
3315         * inspector/InspectorFrontendHost.idl:
3316         * inspector/front-end/DOMExtension.js:
3317         * inspector/front-end/InspectorFrontendHostStub.js:
3318         (.WebInspector.InspectorFrontendHostStub.prototype.canInspectWorkers):
3319         (.WebInspector.InspectorFrontendHostStub.prototype.isUnderTest):
3320         * inspector/front-end/TestController.js:
3321         (.invokeMethod):
3322         (WebInspector.evaluateForTestInFrontend):
3323         * inspector/front-end/externs.js:
3324
3325 2013-01-23  Andrey Lushnikov  <lushnikov@chromium.org>
3326
3327         Web Inspector: remove invisibleLineRow code from paintLines DTE method
3328         https://bugs.webkit.org/show_bug.cgi?id=107649
3329
3330         Reviewed by Pavel Feldman.
3331
3332         Remove invisibleLineRow logic from TextEditorMainPanel._paintLines method.
3333
3334         No new tests: no change in behaviour.
3335
3336         * inspector/front-end/DefaultTextEditor.js:
3337         (WebInspector.TextEditorMainPanel.prototype._paintLines):
3338
3339 2013-01-23  Rafael Weinstein  <rafaelw@chromium.org>
3340
3341         REGRESSION(r140101): caused debug asserts in fast/forms/associated-element-crash.html and html5lib/run-template.html
3342         https://bugs.webkit.org/show_bug.cgi?id=107237
3343
3344         Reviewed by Adam Barth.
3345
3346         No new tests needed.
3347
3348         When the parser foster-parent's a node out of a table context and the foster parent is a template element, set the Task.parent
3349         to be the template element's content, rather than the element itself. This ensures the foster-parented node isn't errorenously
3350         reparented.
3351
3352         * html/parser/HTMLConstructionSite.cpp:
3353         (WebCore::HTMLConstructionSite::findFosterSite):
3354
3355 2013-01-23  Yury Semikhatsky  <yurys@chromium.org>
3356
3357         Web Inspector: heap profiler shows nodes with distance 0
3358         https://bugs.webkit.org/show_bug.cgi?id=107425
3359
3360         Reviewed by Pavel Feldman.
3361
3362         "Document DOM tree" entities now have distance 1. So if there is a DOM
3363         wrapper that is not referenced from javascript it will anyways be shown
3364         in the heap snapshot and will have distance 2. Also such DOM wrappers
3365         are considered to be reachable from user roots (e.g. global Window objects)
3366         otherwice they are not event shown in the heap snapshots.
3367
3368         * inspector/front-end/HeapSnapshot.js:
3369         (WebInspector.HeapSnapshot.prototype.distanceForUserRoot):
3370         (WebInspector.HeapSnapshot.prototype._calculateDistances):
3371         * inspector/front-end/JSHeapSnapshot.js:
3372         (WebInspector.JSHeapSnapshot.prototype.distanceForUserRoot): distance for 
3373         "(Document DOM trees)" is set to 0 to make sure distance of "Ddocument DOM tree" is 1.
3374         (WebInspector.JSHeapSnapshot.prototype._markPageOwnedNodes):
3375         (WebInspector.JSHeapSnapshotNode.prototype.isDocumentDOMTreesRoot):
3376
3377 2013-01-23  Adrian Perez de Castro  <aperez@igalia.com>
3378
3379         [GStreamer] Add Opus MIME type to the list of supported ones
3380         https://bugs.webkit.org/show_bug.cgi?id=98759
3381
3382         Reviewed by Philippe Normand.
3383
3384         GStreamer has support for the Opus codec (http://opus-codec.org) by
3385         using a plugin present in the "gst-plugins-bad" repository. Opus
3386         streams may be embedded in a Ogg container, or standalone. The case
3387         of the Ogg container is already covered by the "*/ogg" MIME types
3388         declared as supported by the GStreamer media playing code, but for
3389         standalone streams to work, "audio/opus" has to be added.
3390
3391         With this, and the needed GStreamer plugin installed, the GTK+
3392         launcher is able to correctly play the example streams from
3393         http://opus-codec.org/examples
3394
3395         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3396
3397 2013-01-23  Takashi Sakamoto  <tasak@google.com>
3398
3399         [Refactoring] Remove elementParentStyle from SelectorCheckerContext
3400         https://bugs.webkit.org/show_bug.cgi?id=107496
3401
3402         Reviewed by Darin Adler.
3403
3404         Since childrenAffectedBy bits were moved from RenderStyle to element,
3405         now elementParentStyle is not used in SelectorChecker and
3406         StyleResolver. We should remove the member varaiable from
3407         SelectorCheckerContext.
3408
3409         No new tests, because just refactoring.
3410
3411         * css/SelectorChecker.cpp:
3412         (WebCore::SelectorChecker::match):
3413         * css/SelectorChecker.h:
3414         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
3415         (SelectorCheckingContext):
3416         * css/StyleResolver.cpp:
3417         (WebCore::StyleResolver::ruleMatches):
3418         Removed elementParentStyle.
3419
3420 2013-01-23  Andreas Kling  <akling@apple.com>
3421
3422         Pass CSSSelector pointers around as const after parsing stage.
3423         <http://webkit.org/b/107645>
3424
3425         Reviewed by Antti Koivisto.
3426
3427         Have CSSSelectorList vend const CSSSelector* and make the style resolution code
3428         operate on const pointers instead.
3429
3430         This gives us some compile-time confidence that nobody is changing the selectors
3431         after we've parsed them.
3432
3433         * css/CSSSelector.cpp:
3434         (WebCore::CSSSelector::operator==):
3435         (WebCore::CSSSelector::selectorText):
3436         (WebCore::CSSSelector::parseNth):
3437         (WebCore::CSSSelector::matchNth):
3438         * css/CSSSelector.h:
3439         (CSSSelector):
3440         (WebCore::CSSSelector::tagHistory):
3441         (WebCore::CSSSelector::selectorList):
3442         * css/CSSSelectorList.cpp:
3443         (WebCore::CSSSelectorList::selectorsText):
3444         (WebCore::forEachTagSelector):
3445         (WebCore::forEachSelector):
3446         (WebCore::SelectorNeedsNamespaceResolutionFunctor::operator()):
3447         (WebCore::SelectorHasInvalidSelectorFunctor::operator()):
3448         * css/CSSSelectorList.h:
3449         (WebCore::CSSSelectorList::first):
3450         (CSSSelectorList):
3451         (WebCore::CSSSelectorList::selectorAt):
3452         (WebCore::CSSSelectorList::indexOfNextSelectorAfter):
3453         (WebCore::CSSSelectorList::next):
3454         * css/CSSStyleRule.cpp:
3455         (WebCore::CSSStyleRule::generateSelectorText):
3456         * css/RuleSet.cpp:
3457         (WebCore::selectorListContainsUncommonAttributeSelector):
3458         (WebCore::collectFeaturesFromRuleData):
3459         * css/RuleSet.h:
3460         (WebCore::RuleData::selector):
3461         (WebCore::RuleSet::RuleSetSelectorPair::RuleSetSelectorPair):
3462         (RuleSetSelectorPair):
3463         * css/SelectorChecker.cpp:
3464         (WebCore::SelectorChecker::matches):
3465         (WebCore::SelectorChecker::match):
3466         (WebCore::SelectorChecker::checkOne):
3467         (WebCore::SelectorChecker::checkScrollbarPseudoClass):
3468         (WebCore::SelectorChecker::determineLinkMatchType):
3469         * css/SelectorChecker.h:
3470         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
3471         (SelectorCheckingContext):
3472         (SelectorChecker):