[GTK] Limit the supported compilers to GCC >= 4.7 and Clang >= 3.0
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-03-07  Zan Dobersek  <zdobersek@igalia.com>
2
3         [GTK] Limit the supported compilers to GCC >= 4.7 and Clang >= 3.0
4         https://bugs.webkit.org/show_bug.cgi?id=109932
5
6         Reviewed by Martin Robinson.
7
8         * GNUmakefile.am: Replace references to SYMBOL_VISIBILITY_INLINES and SYMBOL_VISIBILITY variables with the actual flags.
9         They are now available by default due to the limited set of supported compilers.
10         * bindings/gobject/GNUmakefile.am: Ditto.
11
12 2013-03-07  Mike West  <mkwst@chromium.org>
13
14         XSSAuditor should send only one console error when blocking a page.
15         https://bugs.webkit.org/show_bug.cgi?id=110733
16
17         Reviewed by Daniel Bates.
18
19         Currently, we send two console errors when XSSAuditor blocks a page:
20         "Refused to execute a JavaScript script. Source code of script found
21         within request.\n", and "Entire page will be blocked.".
22
23         We should only send one message, tuning it properly for the context, and
24         including the URL of the page effected by the XSSAuditor's work.
25
26         Covered by rebaselines of all the XSSAuditor and 'reflected-xss' tests.
27
28         * html/parser/XSSAuditor.cpp:
29         * html/parser/XSSAuditor.h:
30         (WebCore::XSSAuditor::XSSAuditor):
31             Add two booleans to track the headers used to set the XSSAuditor state.
32         (WebCore::XSSAuditor::init):
33             Save a copy of the document's URL even if we're not generating a
34             report upon violation: we'll need it for the console messages. Also
35             populate the didSendValidXXXHeader booleans for use later.
36         (WebCore::XSSAuditor::filterToken):
37             Add detail about the header status to the constructed XSSInfo object.
38         * html/parser/XSSAuditorDelegate.cpp:
39         (WebCore::buildConsoleError):
40             Move message construction out into a separate inlined function, as
41             it's becoming complex.
42         (WebCore::XSSAuditorDelegate::didBlockScript):
43             Fold the "Entire page will be blocked" message into the main console
44             error.
45         * html/parser/XSSAuditorDelegate.h:
46         (WebCore::XSSInfo::create):
47         (WebCore::XSSInfo::XSSInfo):
48             Add detail about header status to XSSInfo in order to correctly
49             construct the console error.
50
51 2013-03-07  Vsevolod Vlasov  <vsevik@chromium.org>
52
53         Web Inspector: Add some more compilation annotations to NavigatorView
54         https://bugs.webkit.org/show_bug.cgi?id=111730
55
56         Reviewed by Alexander Pavlov.
57
58         * inspector/front-end/NavigatorView.js:
59
60 2013-03-06  Gustavo Noronha Silva  <gns@gnome.org>
61
62         [GTK] Enable translations for WebKit2
63         https://bugs.webkit.org/show_bug.cgi?id=111398
64
65         Reviewed by Martin Robinson.
66
67         Build change only, thus no tests.
68
69         * GNUmakefile.am: distribute po files.
70         * platform/gtk/po/POTFILES.in: adjust paths for translatable files.
71
72 2013-03-07  Andrey Lushnikov  <lushnikov@chromium.org>
73
74         Web Inspector: [CodeMirror] update codemirror to version 3.1
75         https://bugs.webkit.org/show_bug.cgi?id=111711
76
77         Reviewed by Vsevolod Vlasov.
78
79         Update code mirror experimental editor to version 3.1
80
81         No new tests.
82
83         * inspector/front-end/cm/codemirror.css:
84         (.CodeMirror div.CodeMirror-cursor):
85         (.CodeMirror div.CodeMirror-secondarycursor):
86         (.CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor):
87         (.CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor:not(#nonsense_id)):
88         (.CodeMirror div.CodeMirror-cursor.CodeMirror-overwrite):
89         (.CodeMirror-gutters):
90         (.CodeMirror-linewidget):
91         (.CodeMirror-widget):
92         (.CodeMirror-focused div.CodeMirror-cursor):
93         (@media print):
94         * inspector/front-end/cm/codemirror.js:
95         (window.CodeMirror):
96         (window.CodeMirror.):
97
98 2013-03-07  Sergio Correia  <sergio.correia@openbossa.org>
99
100         OpenGLShims: fix check for ANGLE GLES2 extensions
101         https://bugs.webkit.org/show_bug.cgi?id=111656
102
103         Reviewed by Simon Hausmann.
104
105         The check for ANGLE GLES2 extensions is currently being overriden
106         with checks for APPLE extensions in lookupOpenGLFunctionAddress().
107
108         No new tests. No user visible behavior changed.
109
110         * platform/graphics/OpenGLShims.cpp:
111         (WebCore::lookupOpenGLFunctionAddress):
112
113 2013-03-07  David Kilzer  <ddkilzer@apple.com>
114
115         Rename visible_units.h to VisibleUnits.h in WebCore.vcxproj.filters
116         <http://webkit.org/b/111426>
117
118         * WebCore.vcxproj/WebCore.vcxproj.filters: Rename visible_units.h
119         to VisibleUnits.h and re-sort.
120
121 2013-03-07  Vsevolod Vlasov  <vsevik@chromium.org>
122
123         Web Inspector: Support a shortcut for reloading front-end in debug mode.
124         https://bugs.webkit.org/show_bug.cgi?id=111709
125
126         Reviewed by Pavel Feldman.
127
128         * inspector/front-end/buildSystemOnly.js:
129         * inspector/front-end/inspector.js:
130         (WebInspector.documentKeyDown):
131
132 2013-03-07  Vsevolod Vlasov  <vsevik@chromium.org>
133
134         Web Inspector: Support setting up file system mappings from scripts panel context menu.
135         https://bugs.webkit.org/show_bug.cgi?id=111583
136
137         Reviewed by Pavel Feldman.
138
139         Added context menu items to set up network - file system mappings from sources panel.
140         Implemented mapping add/remove methods on Workspace.
141         Added a dialog suggesting to reload front-end after making such changes.
142
143         * English.lproj/localizedStrings.js:
144         * inspector/front-end/FileSystemMapping.js:
145         (WebInspector.FileSystemMappingImpl.prototype.fileSystemPath):
146         * inspector/front-end/FileSystemProjectDelegate.js:
147         (WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemRemoved):
148         (WebInspector.FileSystemWorkspaceProvider.prototype.fileSystemPath):
149         * inspector/front-end/FilteredItemSelectionDialog.js:
150         (WebInspector.FilteredItemSelectionDialog.prototype.onEnter):
151         (WebInspector.FilteredItemSelectionDialog.prototype.setQuery):
152         (WebInspector.SelectUISourceCodeDialog):
153         (WebInspector.SelectUISourceCodeDialog.prototype.uiSourceCodeSelected):
154         (WebInspector.SelectUISourceCodeDialog.prototype.filterProject):
155         (WebInspector.SelectUISourceCodeDialog.prototype.filterUISourceCode):
156         (WebInspector.SelectUISourceCodeDialog.prototype.selectItem):
157         (WebInspector.SelectUISourceCodeDialog.prototype._uiSourceCodeAdded):
158         (WebInspector.OpenResourceDialog):
159         (WebInspector.OpenResourceDialog.prototype.uiSourceCodeSelected):
160         (WebInspector.OpenResourceDialog.prototype.filterProject):
161         (WebInspector.SelectUISourceCodeForProjectTypeDialog):
162         (WebInspector.SelectUISourceCodeForProjectTypeDialog.prototype.uiSourceCodeSelected):
163         (WebInspector.SelectUISourceCodeForProjectTypeDialog.prototype.filterProject):
164         (WebInspector.SelectUISourceCodeForProjectTypeDialog.show):
165         * inspector/front-end/ScriptsPanel.js:
166         (WebInspector.ScriptsPanel.prototype._mapFileSystemToNetwork.mapFileSystemToNetwork):
167         (WebInspector.ScriptsPanel.prototype._mapFileSystemToNetwork):
168         (WebInspector.ScriptsPanel.prototype._removeNetworkMapping):
169         (WebInspector.ScriptsPanel.prototype._mapNetworkToFileSystem.mapNetworkToFileSystem):
170         (WebInspector.ScriptsPanel.prototype._mapNetworkToFileSystem):
171         (WebInspector.ScriptsPanel.prototype.):
172         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeMappingItems):
173         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeItems):
174         * inspector/front-end/SettingsScreen.js:
175         (WebInspector.WorkspaceSettingsTab):
176         (WebInspector.WorkspaceSettingsTab.prototype.wasShown):
177         (WebInspector.WorkspaceSettingsTab.prototype._reset):
178         * inspector/front-end/ViewportControl.js:
179         (WebInspector.ViewportControl.prototype.refresh):
180         * inspector/front-end/Workspace.js:
181         (WebInspector.Workspace.prototype.addMapping):
182         (WebInspector.Workspace.prototype.removeMapping):
183         * inspector/front-end/externs.js:
184         (WebInspector.suggestReload):
185         * inspector/front-end/inspector.js:
186         (WebInspector.suggestReload):
187
188 2013-03-07  Vsevolod Vlasov  <vsevik@chromium.org>
189
190         Web Inspector: Add support for frontend reloading
191         https://bugs.webkit.org/show_bug.cgi?id=111727
192
193         Reviewed by Pavel Feldman.
194
195         This patch adds support for frontend reloading including:
196           - making sure no messages are sent to backend once frontend started reloading
197           - updating frontend url with up-to-date dockSide query parameter value.
198
199         * inspector/front-end/InspectorBackend.js:
200         (InspectorBackendClass.prototype.sendMessageObjectToBackend):
201         (InspectorBackendClass.prototype.disconnect):
202         * inspector/front-end/externs.js:
203         (WebInspector.reload):
204         * inspector/front-end/inspector.js:
205         (WebInspector.reload):
206
207 2013-03-07  Alexei Filippov  <alph@chromium.org>
208
209         Web Inspector: Change profile start button caption depending on profile type.
210         https://bugs.webkit.org/show_bug.cgi?id=111698
211
212         Change the start profiling button caption to "Snapshot" for
213         snapshot-like profile types, e.g. JS heap snapshot, native memory snapshot.
214
215         Reviewed by Yury Semikhatsky.
216
217         * English.lproj/localizedStrings.js:
218         * inspector/front-end/HeapSnapshotView.js:
219         (WebInspector.HeapSnapshotProfileType.prototype.isInstantProfile):
220         * inspector/front-end/NativeMemorySnapshotView.js:
221         (WebInspector.NativeSnapshotProfileType.prototype.isInstantProfile):
222         (WebInspector.NativeMemoryProfileType.prototype.isInstantProfile):
223         * inspector/front-end/ProfileLauncherView.js:
224         (WebInspector.ProfileLauncherView):
225         (WebInspector.ProfileLauncherView.prototype.addProfileType):
226         (WebInspector.ProfileLauncherView.prototype._updateControls):
227         (WebInspector.MultiProfileLauncherView.prototype._updateControls):
228         (WebInspector.MultiProfileLauncherView.prototype._profileTypeChanged):
229         * inspector/front-end/ProfilesPanel.js:
230         (WebInspector.ProfileType.prototype.isInstantProfile):
231
232 2013-03-07  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
233
234         [texmap] Remove direct access to clip state from clip stack
235         https://bugs.webkit.org/show_bug.cgi?id=111630
236
237         Reviewed by Allan Sandfeld Jensen.
238
239         As we are now monitoring the clip state from
240         TextureMapperGL/BitmapTextureGL, have direct access to clip state object
241         would eventually make it dirty without properly setting the
242         'clipStateDirty' flag. This bug intends to substitute direct access with
243         auxiliary functions which would set the clip state dirty when necessary.
244
245         No new tests. No user visible behavior changed.
246
247         * platform/graphics/texmap/TextureMapperGL.cpp:
248         (WebCore::TextureMapperGL::ClipStack::intersect):
249         (WebCore::TextureMapperGL::ClipStack::setStencilIndex):
250         (WebCore::TextureMapperGL::drawBorder):
251         (WebCore::TextureMapperGL::drawTexture):
252         (WebCore::TextureMapperGL::beginScissorClip):
253         (WebCore::TextureMapperGL::beginClip):
254         Replaced direct access with auxiliary functions.
255
256         * platform/graphics/texmap/TextureMapperGL.h:
257         (ClipStack): Removed ClipStack::current() function.
258         (WebCore::TextureMapperGL::ClipStack::getStencilIndex): Added.
259         (WebCore::TextureMapperGL::ClipStack::isCurrentScissorBoxEmpty): Added.
260
261 2013-03-07  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
262
263         [Texturemapper] transform-style 'flat' value is broken
264         https://bugs.webkit.org/show_bug.cgi?id=111566
265
266         Reviewed by Allan Sandfeld Jensen.
267
268         After changes from r144290, the CSS3 'transform-styles' property, when
269         used with 'flat' value, resulted in non-stenciled rendering inside
270         clipped area - vide example from Surfin' Safari blog:
271         https://www.webkit.org/blog-files/3d-transforms/transform-style.html
272
273         This patch forces the clip state to be applied when binding the default
274         surface.
275
276         No new tests. No user visible behavior changed.
277
278         * platform/graphics/texmap/TextureMapperGL.cpp:
279         (WebCore::TextureMapperGL::ClipStack::apply):
280         (WebCore::TextureMapperGL::ClipStack::applyIfNeeded): Added.
281         Moved state cache check from apply() to applyIfNeeded().
282
283         (WebCore::BitmapTextureGL::clearIfNeeded):
284         (WebCore::BitmapTextureGL::bind):
285         (WebCore::TextureMapperGL::beginScissorClip):
286         (WebCore::TextureMapperGL::beginClip):
287         (WebCore::TextureMapperGL::endClip):
288         * platform/graphics/texmap/TextureMapperGL.h:
289         (ClipStack):
290         Use applyIfNeeded() to check for clip state before clipping.
291
292 2013-03-07  Andrey Lushnikov  <lushnikov@chromium.org>
293
294         Web Inspector: refactoring: move TextEditorModel.Indent enum into TextUtils
295         https://bugs.webkit.org/show_bug.cgi?id=111715
296
297         Reviewed by Pavel Feldman.
298
299         Move WebInspector.TextEditorModel.Indent into WebInspector.TextUtils namespace.
300
301         No new tests: no change in behaviour.
302
303         * inspector/front-end/SettingsScreen.js:
304         (WebInspector.GenericSettingsTab):
305         * inspector/front-end/TextEditorModel.js:
306         (WebInspector.TextEditorModel.endsWithBracketRegex.):
307         * inspector/front-end/TextUtils.js:
308
309 2013-03-07  Ian Vollick  <vollick@chromium.org>
310
311         Fix painting phases for composited scrolling
312         https://bugs.webkit.org/show_bug.cgi?id=107618
313
314         Reviewed by Simon Fraser.
315
316         With composited scrolling, the scrolling contents layer paints the 
317         foreground and the main graphics layer paints the background. This 
318         causes a few problems:
319
320           1) If we create a foreground layer, we end up with two layers painting 
321              the foreground phase.
322           2) Focus rings / outlines paint into the foreground layer, so they end
323              up moving around with the scrolling contents.
324           3) Neg z-order descendants paint in the the main graphics layer and
325              will therefore not scroll.
326
327         To deal with 1) we need to stop painting the foreground into both the
328         foreground and scrolling contents layers. We also need to ensure that
329         the foreground layer is the right size and has the right offset from
330         renderer if we're on the composited scrolling path.
331
332         To deal with 2) and 3), I have added a new graphics layer painting phase 
333         flag -- GraphicsLayerPaintCompositedScroll -- and applied it to two
334         layers in the subtree created by RenderLayerBacking. This ultimately
335         affects the paint phase passed to RenderLayer::paintLayerContents and
336         allows us to paint the focus rings, outlines and negative z-order
337         descendants into the proper layers.
338
339         Tests: compositing/overflow/composited-scrolling-paint-phases.html
340                compositing/overflow/do-not-paint-outline-into-composited-scrolling-contents.html
341                compositing/overflow/paint-neg-z-order-descendants-into-scrolling-contents-layer.html
342
343         * page/Frame.h:
344           Added a flag for including painting phases in the layer tree dump.
345         (WebCore::GraphicsLayer::dumpProperties):
346           Can now dump painting phase information, but only if requested.
347         * platform/graphics/GraphicsLayerClient.h:
348           Added a new entry to GraphicsLayerPaintingPhaseFlags for comp-scroll.
349         (WebCore::RenderLayer::paintLayerContents):
350           Updated the logic to account for the new comp-scroll-related paint
351           phase flag.
352         * rendering/RenderLayer.h:
353           Added the RenderLayer painting phase counterpart to
354           GraphicsLayerPaintCompositedScroll.
355         * rendering/RenderLayerBacking.cpp:
356         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
357           Ensures that the foreground layer is sized correctly for comp-scroll.
358         (WebCore::RenderLayerBacking::updateScrollingLayers):
359           If we have a foreground layer, the scrolling contents layer no
360           longer gets assigned the foreground painting phase.
361         (WebCore::RenderLayerBacking::paintingPhaseForPrimaryLayer):
362           If we're comp-scrolling, then the primary layer gets the new phase.
363         (WebCore::RenderLayerBacking::paintIntoLayer):
364           Simply translates the new graphics layer painting phase to its
365           render layer counterpart.
366         (WebCore::RenderLayerCompositor::layerTreeAsText):
367         * testing/Internals.cpp:
368         (WebCore::Internals::layerTreeAsText):
369         * testing/Internals.h:
370         * testing/Internals.idl:
371           The above changes are solely plumbing to allow layout tests to
372           request that paint phase information be included in the layer tree
373           dump.
374
375 2013-03-07  Allan Sandfeld Jensen  <allan.jensen@digia.com>
376
377         [Qt] Use Qt5.1 supportedMimeTypes methods.
378         https://bugs.webkit.org/show_bug.cgi?id=111185
379
380         Reviewed by Jocelyn Turcotte.
381
382         Uses the supportedMimeTypes() methods from QImageReader and QImageWriter when available.
383
384         * platform/MIMETypeRegistry.cpp:
385         (WebCore::initializeSupportedImageMIMETypes):
386         (WebCore::initializeSupportedImageMIMETypesForEncoding):
387
388 2013-03-07  Ilya Tikhonovsky  <loislo@chromium.org>
389
390         Web Inspector: Flame Chart. Stick item color to the function.
391         https://bugs.webkit.org/show_bug.cgi?id=111697
392
393         Reviewed by Yury Semikhatsky.
394
395         Different nodes associated with a single function have to use the same color.
396         Minor polish: do not filter out (idle) and (program) items. They were big due to an error on v8 side.
397         Set minimum width to 0 for more precise picture.
398
399         * inspector/front-end/FlameChart.js:
400         (WebInspector.FlameChart):
401         (WebInspector.FlameChart.prototype._rootNodes):
402         (WebInspector.FlameChart.prototype.draw):
403         (WebInspector.FlameChart.prototype._drawNode):
404         (WebInspector.FlameChart.prototype._drawBar):
405
406 2013-03-07  Andrey Lushnikov  <lushnikov@chromium.org>
407
408         Web Inspector: [ACE] gutter size should be fixed.
409         https://bugs.webkit.org/show_bug.cgi?id=111576
410
411         Reviewed by Pavel Feldman.
412
413         Add a custom ace editor build that supports setFixedGutterWidth configuration
414         parameter and switch this setting on.
415
416         No new tests.
417
418         * inspector/front-end/AceTextEditor.js:
419         (WebInspector.AceTextEditor): Switch fixedGutterWidth setting on.
420         * inspector/front-end/ace/ace.js:
421         (.):
422
423 2013-03-07  Sheriff Bot  <webkit.review.bot@gmail.com>
424
425         Unreviewed, rolling out r145059.
426         http://trac.webkit.org/changeset/145059
427         https://bugs.webkit.org/show_bug.cgi?id=111707
428
429         crash webkit build (Requested by tasak on #webkit).
430
431         * CMakeLists.txt:
432         * GNUmakefile.list.am:
433         * Target.pri:
434         * WebCore.gypi:
435         * WebCore.xcodeproj/project.pbxproj:
436         * css/CSSAllInOne.cpp:
437         * css/DocumentRuleSets.cpp:
438         (WebCore::ShadowDistributedRules::collectMatchRequests):
439         * css/DocumentRuleSets.h:
440         * css/ElementRuleCollector.cpp: Removed.
441         * css/ElementRuleCollector.h: Removed.
442         * css/PageRuleCollector.cpp: Removed.
443         * css/PageRuleCollector.h: Removed.
444         * css/StyleResolver.cpp:
445         (WebCore::leftToRightDeclaration):
446         (WebCore):
447         (WebCore::rightToLeftDeclaration):
448         (WebCore::StyleResolver::State::ensureRuleList):
449         (WebCore::StyleResolver::State::clear):
450         (WebCore::StyleResolver::addMatchedProperties):
451         (WebCore::StyleResolver::addElementStyleProperties):
452         (MatchingUARulesScope):
453         (WebCore::MatchingUARulesScope::MatchingUARulesScope):
454         (WebCore::MatchingUARulesScope::~MatchingUARulesScope):
455         (WebCore::MatchingUARulesScope::isMatchingUARules):
456         (WebCore::StyleResolver::collectMatchingRules):
457         (WebCore::StyleResolver::collectMatchingRulesForRegion):
458         (WebCore::StyleResolver::sortAndTransferMatchedRules):
459         (WebCore::StyleResolver::matchScopedAuthorRules):
460         (WebCore::StyleResolver::matchHostRules):
461         (WebCore::StyleResolver::matchAuthorRules):
462         (WebCore::StyleResolver::matchUserRules):
463         (WebCore::StyleResolver::matchUARules):
464         (WebCore::StyleResolver::collectMatchingRulesForList):
465         (WebCore::compareRules):
466         (WebCore::StyleResolver::sortMatchedRules):
467         (WebCore::StyleResolver::matchAllRules):
468         (WebCore::StyleResolver::State::initForStyleResolve):
469         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
470         (WebCore::StyleResolver::styleForElement):
471         (WebCore::StyleResolver::styleForKeyframe):
472         (WebCore::StyleResolver::pseudoStyleForElement):
473         (WebCore::StyleResolver::styleForPage):
474         (WebCore::StyleResolver::pseudoStyleRulesForElement):
475         (WebCore::StyleResolver::ruleMatches):
476         (WebCore::StyleResolver::checkRegionSelector):
477         (WebCore::comparePageRules):
478         (WebCore::StyleResolver::matchPageRules):
479         (WebCore::checkPageSelectorComponents):
480         (WebCore::StyleResolver::matchPageRulesForList):
481         (WebCore::StyleResolver::isLeftPage):
482         (WebCore::StyleResolver::isFirstPage):
483         (WebCore::StyleResolver::pageName):
484         * css/StyleResolver.h:
485         (WebCore::MatchRequest::MatchRequest):
486         (MatchRequest):
487         (StyleResolver):
488         (MatchResult):
489         (WebCore::StyleResolver::State::State):
490         (State):
491         (WebCore::StyleResolver::State::takeRuleList):
492         (WebCore::StyleResolver::State::setSameOriginOnly):
493         (WebCore::StyleResolver::State::isSameOriginOnly):
494         (WebCore::StyleResolver::State::pseudoStyleRequest):
495         (WebCore::StyleResolver::State::setMode):
496         (WebCore::StyleResolver::State::mode):
497         (WebCore::StyleResolver::State::matchedRules):
498         (WebCore::StyleResolver::State::addMatchedRule):
499         * inspector/InspectorCSSAgent.cpp:
500         (WebCore::InspectorCSSAgent::willMatchRule):
501         * inspector/InspectorCSSAgent.h:
502         (WebCore):
503         (InspectorCSSAgent):
504         * inspector/InspectorInstrumentation.cpp:
505         (WebCore):
506         (WebCore::InspectorInstrumentation::willMatchRuleImpl):
507         * inspector/InspectorInstrumentation.h:
508         (WebCore):
509         (InspectorInstrumentation):
510         (WebCore::InspectorInstrumentation::willMatchRule):
511
512 2013-03-07  Kentaro Hara  <haraken@chromium.org>
513
514         Unreviewed. Rebaselined run-bindings-tests.
515
516         * bindings/scripts/test/V8/V8TestInterface.cpp:
517         (WebCore):
518         * bindings/scripts/test/V8/V8TestObj.cpp:
519         (WebCore):
520
521 2013-03-07  Takashi Sakamoto  <tasak@google.com>
522
523         [Refactoring] Implement RuleCollector
524         https://bugs.webkit.org/show_bug.cgi?id=109916
525
526         Reviewed by Antti Koivisto.
527
528         Implemented rule collector for an element and collector for a page.
529         Not all members in class State are required entire while resolving
530         a style.
531
532         No new tests, because just refactoring.
533
534         * CMakeLists.txt:
535         * GNUmakefile.list.am:
536         * Target.pri:
537         * WebCore.gypi:
538         * WebCore.xcodeproj/project.pbxproj:
539         * css/CSSAllInOne.cpp:
540         Added ElementRuleCollector and PageRuleCollector.
541         * css/DocumentRuleSets.cpp:
542         (WebCore::ShadowDistributedRules::collectMatchRequests):
543         Since behaviorAtBoundary is a state owned by ElementRuleCollector,
544         removed from here.
545         * css/DocumentRuleSets.h:
546         (WebCore::ShadowDistributedRules::isEmpty):
547         Added to quickly check whether there exist any ShadowDistributedRules
548         or not.
549         * css/ElementRuleCollector.cpp: Copied from Source/WebCore/css/StyleResolver.cpp.
550         (WebCore):
551         (WebCore::ElementRuleCollector::matchedResult):
552         (WebCore::ElementRuleCollector::matchedRuleList):
553         (WebCore::ElementRuleCollector::addMatchedRule):
554         (WebCore::ElementRuleCollector::clearMatchedRules):
555         (WebCore::ElementRuleCollector::ensureRuleList):
556         (WebCore::ElementRuleCollector::addElementStyleProperties):
557         (WebCore::ElementRuleCollector::collectMatchingRules):
558         (WebCore::ElementRuleCollector::collectMatchingRulesForRegion):
559         (WebCore::ElementRuleCollector::sortAndTransferMatchedRules):
560         (WebCore::ElementRuleCollector::matchScopedAuthorRules):
561         (WebCore::ElementRuleCollector::matchHostRules):
562         (WebCore::ElementRuleCollector::matchShadowDistributedRules):
563         (WebCore::ElementRuleCollector::matchAuthorRules):
564         (WebCore::ElementRuleCollector::matchUserRules):
565         (WebCore::ElementRuleCollector::matchUARules):
566         (WebCore::ElementRuleCollector::ruleMatches):
567         (WebCore::ElementRuleCollector::collectMatchingRulesForList):
568         (WebCore::ElementRuleCollector::sortMatchedRules):
569         (WebCore::ElementRuleCollector::matchAllRules):
570         Moved these methods from StyleResolver to this class.
571         (WebCore::ElementRuleCollector::hasAnyMatchingRules):
572         This method is used for checking whether a given element can share
573         a cache.
574         * css/ElementRuleCollector.h: Copied from Source/WebCore/css/StyleResolver.h.
575         (WebCore):
576         (WebCore::ElementRuleCollector::ElementRuleCollector):
577         Use styleResolver instance to initialize its member variables, i.e.
578         SelectorFilter, RuleSets, InspectorCSSOMWrappers, and
579         StyleScopedResolver.
580         (ElementRuleCollector):
581         (WebCore::ElementRuleCollector::setMode):
582         (WebCore::ElementRuleCollector::setPseudoStyleRequest):
583         (WebCore::ElementRuleCollector::setSameOriginOnly):
584         (WebCore::ElementRuleCollector::setRegionForStyling):
585         Mode, SameOriginOnly, RegionForStyling are only used while collecting
586         matched rules.
587         (WebCore::ElementRuleCollector::setMedium):
588         Need to know which default stylesheet should be looked up.
589         (WebCore::ElementRuleCollector::document):
590         * css/PageRuleCollector.cpp: Copied from Source/WebCore/css/StyleResolver.cpp.
591         (WebCore::comparePageRules):
592         (WebCore::PageRuleCollector::isLeftPage):
593         (WebCore::PageRuleCollector::isFirstPage):
594         (WebCore::PageRuleCollector::pageName):
595         (WebCore::PageRuleCollector::matchAllPageRules):
596         (WebCore::PageRuleCollector::matchPageRules):
597         (WebCore::checkPageSelectorComponents):
598         (WebCore::PageRuleCollector::matchPageRulesForList):
599         Moved from StyleResolver.
600         * css/PageRuleCollector.h: Copied from Source/WebCore/css/StyleResolver.h.
601         (WebCore):
602         (WebCore::PageRuleCollector::PageRuleCollector):
603         (PageRuleCollector):
604         (WebCore::PageRuleCollector::matchedResult):
605         * css/StyleResolver.cpp:
606         (WebCore):
607         (WebCore::StyleResolver::State::clear):
608         (WebCore::StyleResolver::MatchResult::addMatchedProperties):
609         (WebCore::StyleResolver::State::initForStyleResolve):
610         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
611         (WebCore::StyleResolver::styleForElement):
612         (WebCore::StyleResolver::styleForKeyframe):
613         (WebCore::StyleResolver::pseudoStyleForElement):
614         (WebCore::StyleResolver::styleForPage):
615         (WebCore::StyleResolver::pseudoStyleRulesForElement):
616         (WebCore::StyleResolver::applyMatchedProperties):
617         * css/StyleResolver.h:
618         (WebCore::MatchRequest::MatchRequest):
619         Removed behaviorAtBoundary. Instead, ElementRuleCollector have the
620         state.
621         (MatchRequest):
622         (WebCore::StyleResolver::selectorFilter):
623         Added to obtain SelectorFilter in ElementRuleCollector's constructor.
624         (StyleResolver):
625         (MatchResult):
626         (WebCore::StyleResolver::State::State):
627         To pass ASSERT in StyleResolver::applyProperties, need to keep
628         m_regionForStyling.
629         (State):
630         (WebCore::StyleResolver::State::regionForStyling):
631         (WebCore::StyleResolver::State::useSVGZoomRules):
632         (WebCore::StyleResolver::hasSelectorForId):
633         (WebCore):
634         (WebCore::checkRegionSelector):
635         * inspector/InspectorCSSAgent.cpp:
636         (WebCore::InspectorCSSAgent::willMatchRule):
637         Removed StyleResolver from its parameter list. Instead, added
638         InspectorCSSOMWrappers and DocumentStyleSheetCollection.
639         * inspector/InspectorCSSAgent.h:
640         (WebCore):
641         (InspectorCSSAgent):
642         * inspector/InspectorInstrumentation.cpp:
643         (WebCore):
644         (WebCore::InspectorInstrumentation::willMatchRuleImpl):
645         * inspector/InspectorInstrumentation.h:
646         (WebCore):
647         (InspectorInstrumentation):
648         (WebCore::InspectorInstrumentation::willMatchRule):
649
650 2013-03-07  Andrey Lushnikov  <lushnikov@chromium.org>
651
652         Web Inspector: [ACE] add experimental breakpoint support
653         https://bugs.webkit.org/show_bug.cgi?id=111573
654
655         Reviewed by Pavel Feldman.
656
657         No new tests.
658
659         - Implement attributes model for ace editor. Update attribute
660         locations by handling onTextChange event from editor.
661         - Implement breakpoints atop of attributes model.
662
663         * inspector/front-end/AceTextEditor.js:
664         (WebInspector.AceTextEditor):
665         (WebInspector.AceTextEditor.prototype._updateBreakpoints):
666         (WebInspector.AceTextEditor.prototype._updateLineAttributes):
667         (WebInspector.AceTextEditor.prototype._onTextChange):
668         (WebInspector.AceTextEditor.prototype.addBreakpoint):
669         (WebInspector.AceTextEditor.prototype.removeBreakpoint):
670         (WebInspector.AceTextEditor.prototype.getAttribute):
671         (WebInspector.AceTextEditor.prototype.setAttribute):
672         (WebInspector.AceTextEditor.prototype.removeAttribute):
673         * inspector/front-end/ace/acedevtools.css:
674         (.ace-editor-container):
675         (.ace_gutter-cell.webkit-breakpoint):
676         (.ace_gutter-cell.webkit-breakpoint-conditional):
677         (.ace_gutter-cell.webkit-breakpoint-disabled):
678         (.ace_gutter-cell):
679
680 2013-03-07  Antoine Quint  <graouts@apple.com>
681
682         Web Inspector: identify layers for CSS generated content in LayerTreeAgent
683         https://bugs.webkit.org/show_bug.cgi?id=111551
684
685         Layers can be associated with pseudo elements, elements that are generated
686         when ::before or ::after pseudo-classes are used to style an element and
687         provide additional rendering using the CSS "content" property. In order to
688         identify that a layer is associated to a pseudo element, we add a new set of
689         optional properties on the Layer object: "isGeneratedContent", "pseudoElementId"
690         and "pseudoClass".
691
692         We need to provide the "pseudoElementId" for the same reason we provide a
693         "nodeId" for the Layer. This is so that the front-end can identify that a
694         layer whose "layerId" may have changed between two layer tree updates is
695         used to render content for the same pseudo element.
696
697         In the instance that a layer is rendering generated content, we also set
698         the "nodeId" to be the generating node's id. The generating node is the
699         node in the DOM that the user styled using ::before or ::after pseudo-classes.
700         We also add the pseudo-class used as the "pseudoClass" property such that the
701         front-end may provide useful information to the user about what type of
702         pseudo-class yielded the generation of this layer. We also deal with the
703         possibility that the layer is a reflection for a pseudo element.
704     
705         Since pseudo elements are not part of the user-visible DOM, and thus can't be
706         pushed to the front-end, we maintain a special ID hash map in the LayerTreeAgent.
707         In order to be able to unbind a pseudo element id and a pseudo element, we add a
708         destructor method to PseudoElement and provide a new instrumentation call so that
709         the LayerTreeAgent may be notified of a PseudoElement being destroyed. This
710         reflects the principle we use to update the RenderLayer bindings when a
711         RenderLayer is destroyed, as notified by the RenderLayerCompositor.
712
713         Reviewed by Simon Fraser.
714
715         Test: inspector-protocol/layers/layers-generated-content.html
716
717         * dom/PseudoElement.cpp:
718         (WebCore::PseudoElement::~PseudoElement): New destructor used to notify
719         InspectorInstrumentation of a PseudoElement being destroyed, such that
720         it can eventually be relayed to the InspectorLayerTreeAgent.
721         (WebCore):
722         * dom/PseudoElement.h:
723         (PseudoElement):
724         * inspector/Inspector.json: Add the new PseudoElementId type used for
725         the new "pseudoElementId" property on Layer, to which we also add the
726         "isGeneratedContent" and "pseudoClass" properties.
727         * inspector/InspectorInstrumentation.cpp:
728         (WebCore):
729         (WebCore::InspectorInstrumentation::pseudoElementDestroyedImpl):
730         * inspector/InspectorInstrumentation.h:
731         (WebCore):
732         (InspectorInstrumentation):
733         (WebCore::InspectorInstrumentation::pseudoElementDestroyed): New method
734         called in the PseudoElement destructor used to relay the fact that a
735         PseudoElement was destroyed to the InspectorLayerTreeAgent.
736         * inspector/InspectorLayerTreeAgent.cpp:
737         (WebCore::InspectorLayerTreeAgent::reset): Clear the new PseudoElement
738         identifier maps.
739         (WebCore::InspectorLayerTreeAgent::pseudoElementDestroyed): Remove any
740         identifier binding for the provided PseudoElement being destroyed.
741         (WebCore):
742         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer): Set the new
743         "isGeneratedContent", "pseudoElementId" and "pseudoClass" properties on
744         the Layer object for layers associated with a pseudo element.
745         (WebCore::InspectorLayerTreeAgent::bind): Use emptyString() instead of "".
746         (WebCore::InspectorLayerTreeAgent::unbind): Use an iterator instead of a
747         get() and remove() combination in order to reduce lookups and mimick the
748         code written for unbindPseudoElement().
749         (WebCore::InspectorLayerTreeAgent::bindPseudoElement): Binds the provided
750         PseudoElement to a unique identifier.
751         (WebCore::InspectorLayerTreeAgent::unbindPseudoElement): Unbinds the
752         provided PseudoElement from its unique identifier.
753         * inspector/InspectorLayerTreeAgent.h:
754         (InspectorLayerTreeAgent):
755
756 2013-03-07  Keishi Hattori  <keishi@webkit.org>
757
758         Add clear button to date/time input types
759         https://bugs.webkit.org/show_bug.cgi?id=111319
760
761         Reviewed by Kent Tamura.
762
763         We want to remove the clear button from the calendar picker (Bug 109439)
764         so we are adding the clear button to the right side of the input element.
765
766         Tests: fast/forms/date-multiple-fields/date-multiple-fields-clearbutton-change-and-input-events.html
767                fast/forms/datetimelocal-multiple-fields/datetimelocal-multiple-fields-clearbutton-change-and-input-events.html
768                fast/forms/month-multiple-fields/month-multiple-fields-clearbutton-change-and-input-events.html
769                fast/forms/time-multiple-fields/time-multiple-fields-clearbutton-change-and-input-events.html
770                fast/forms/week-multiple-fields/week-multiple-fields-clearbutton-change-and-input-events.html
771
772         * CMakeLists.txt: Added ClearButtonElement.cpp
773         * GNUmakefile.list.am: Ditto.
774         * Target.pri: Ditto.
775         * WebCore.gypi: Ditto.
776         * WebCore.vcproj/WebCore.vcproj: Ditto.
777         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
778         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
779         * WebCore.xcodeproj/project.pbxproj: Ditto.
780         * css/html.css:
781         (input::-webkit-clear-button): Styles for the clear button.
782         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
783         (WebCore::BaseMultipleFieldsDateAndTimeInputType::editControlValueChanged):
784         (WebCore::BaseMultipleFieldsDateAndTimeInputType::BaseMultipleFieldsDateAndTimeInputType):
785         (WebCore::BaseMultipleFieldsDateAndTimeInputType::~BaseMultipleFieldsDateAndTimeInputType):
786         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
787         (WebCore::BaseMultipleFieldsDateAndTimeInputType::destroyShadowSubtree):
788         (WebCore::BaseMultipleFieldsDateAndTimeInputType::disabledAttributeChanged):
789         (WebCore::BaseMultipleFieldsDateAndTimeInputType::requiredAttributeChanged): Hide clear button if the value is required.
790         (WebCore):
791         (WebCore::BaseMultipleFieldsDateAndTimeInputType::readonlyAttributeChanged):
792         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue):
793         (WebCore::BaseMultipleFieldsDateAndTimeInputType::focusAndSelectClearButtonOwner): Called on mouse down on clear button.
794         (WebCore::BaseMultipleFieldsDateAndTimeInputType::shouldClearButtonRespondToMouseEvents):
795         (WebCore::BaseMultipleFieldsDateAndTimeInputType::clearValue):
796         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updateClearButtonVisibility): We want to hide the clear button if the value is required or the value is empty.
797         * html/BaseMultipleFieldsDateAndTimeInputType.h:
798         (BaseMultipleFieldsDateAndTimeInputType):
799         * html/HTMLInputElement.cpp:
800         (WebCore::HTMLInputElement::updateClearButtonVisibility):
801         (WebCore):
802         (WebCore::HTMLInputElement::requiredAttributeChanged):
803         * html/HTMLInputElement.h:
804         (HTMLInputElement):
805         * html/InputType.cpp:
806         (WebCore::InputType::requiredAttributeChanged): Notifies the InputType that the required attribute has changed.
807         (WebCore):
808         (WebCore::InputType::updateClearButtonVisibility):
809         * html/InputType.h:
810         (InputType):
811         * html/shadow/ClearButtonElement.cpp: Added.
812         (WebCore):
813         (WebCore::ClearButtonElement::ClearButtonElement):
814         (WebCore::ClearButtonElement::create):
815         (WebCore::ClearButtonElement::detach):
816         (WebCore::ClearButtonElement::releaseCapture): Stop capturing mouse events.
817         (WebCore::ClearButtonElement::defaultEventHandler):
818         * html/shadow/ClearButtonElement.h: Added.
819         (WebCore):
820         (ClearButtonElement):
821         (ClearButtonOwner):
822         (WebCore::ClearButtonElement::ClearButtonOwner::~ClearButtonOwner):
823         (WebCore::ClearButtonElement::removeClearButtonOwner):
824         (WebCore::ClearButtonElement::isMouseFocusable):
825
826 2013-03-07  Eugene Klyuchnikov  <eustas@chromium.org>
827
828         Web Inspector: Refactorings: Prepare SuggestBox for reuse.
829         https://bugs.webkit.org/show_bug.cgi?id=111301
830
831         Reviewed by Alexander Pavlov.
832
833         1) Remove userEnteredText from delegate interface.
834            Pass prefix to updateSuggestions instead.
835         2) Clarify that suggestions array is never null.
836
837         * inspector/front-end/SuggestBox.js:
838         (WebInspector.SuggestBox): Renamed parameter/member.
839         (WebInspector.SuggestBox.prototype._updateItems):
840         Minor readability changes.
841         (WebInspector.SuggestBox.prototype._canShowBox):
842         Use userEnteredText parameter.
843         (WebInspector.SuggestBox.prototype.updateSuggestions):
844         Pass userEnteredText to _canShowBox.
845         * inspector/front-end/DatabaseQueryView.js: Fix JSDocs.
846         * inspector/front-end/RuntimeModel.js: Ditto.
847         * inspector/front-end/TextPrompt.js: Ditto.
848         (WebInspector.TextPrompt.prototype._completionsReady):
849         Pass userEnteredText to updateSuggestions.
850
851 2013-03-07  Victor Carbune  <vcarbune@chromium.org>
852
853         TextTrackRegion Constructor
854         https://bugs.webkit.org/show_bug.cgi?id=110511
855
856         Reviewed by Adam Barth.
857
858         This is an initial patch for implementing the TextTrackRegion
859         defined in the "WebVTT Extension: Regions for rendering cue groups":
860         https://dvcs.w3.org/hg/text-tracks/raw-file/default/608toVTT/region.html
861
862         The feature components are hidden behind the WEBVTT_REGIONS flag
863         and is currently disabled by default in all ports and tests skipped.
864
865         Test: media/track/regions-webvtt/text-track-region-constructor.html
866
867         * WebCore.gypi: Added files to be included for building Chromium with
868         feature enabled (it is disabled by default).
869         * html/track/TextTrackRegion.cpp: Added.
870         (WebCore):
871         (WebCore::TextTrackRegion::TextTrackRegion):
872         (WebCore::TextTrackRegion::~TextTrackRegion):
873         (WebCore::TextTrackRegion::setId): Setter.
874         (WebCore::TextTrackRegion::setWidth): Setter.
875         (WebCore::TextTrackRegion::setHeight): Setter.
876         (WebCore::TextTrackRegion::setRegionAnchorX): Setter.
877         (WebCore::TextTrackRegion::setRegionAnchorY): Setter.
878         (WebCore::TextTrackRegion::setViewportAnchorX): Setter.
879         (WebCore::TextTrackRegion::setViewportAnchorY): Setter.
880         (WebCore::TextTrackRegion::scroll): Getter. Internally, the scroll
881         value is stored as a boolean, but when returned is converted to either
882         the empty string or "up".
883         (WebCore::TextTrackRegion::setScroll): Setter.
884         (WebCore::TextTrackRegion::setRegionSettings): Not used yet (see b/109818)
885         * html/track/TextTrackRegion.h: Added.
886         (WebCore):
887         (TextTrackRegion):
888         (WebCore::TextTrackRegion::create):
889         (WebCore::TextTrackRegion::track): Getter.
890         (WebCore::TextTrackRegion::id): Getter.
891         (WebCore::TextTrackRegion::width): Getter.
892         (WebCore::TextTrackRegion::height): Getter.
893         (WebCore::TextTrackRegion::regionAnchorX): Getter.
894         (WebCore::TextTrackRegion::regionAnchorY): Getter.
895         (WebCore::TextTrackRegion::viewportAnchorX): Getter.
896         (WebCore::TextTrackRegion::viewportAnchorY): Getter.
897         (WebCore::TextTrackRegion::regionSettings): Getter, used only internally (see b/109818).
898         * html/track/TextTrackRegion.idl: Added.
899         * page/DOMWindow.idl: Constructor support.
900
901 2013-03-07  Dan Carney  <dcarney@google.com>
902
903         [v8] remove latin-1 transition flag
904         https://bugs.webkit.org/show_bug.cgi?id=111692
905
906         Reviewed by Jochen Eisinger.
907
908         No new tests. No change in functionality.
909
910         * bindings/v8/V8ValueCache.cpp:
911         (WebCore::makeExternalString):
912
913 2013-03-07  Vsevolod Vlasov  <vsevik@chromium.org>
914
915         Web Inspector: NavigatorView should show (program) for uiSourceCodes with empty name.
916         https://bugs.webkit.org/show_bug.cgi?id=111691
917
918         Reviewed by Alexander Pavlov.
919
920         Made String.prototype methods return string literal, not String object.
921
922         * inspector/front-end/utilities.js:
923         (String.prototype.escapeCharacters):
924
925 2013-03-07  Eugene Klyuchnikov  <eustas@chromium.org>
926
927         Web Inspector: Cmd+L (Go-to-Line) masks Go to location bar action
928         https://bugs.webkit.org/show_bug.cgi?id=111357
929
930         Reviewed by Pavel Feldman.
931
932         Allow panel shortcut handlers to bubble event.
933
934         * inspector/front-end/GoToLineDialog.js:
935         (WebInspector.GoToLineDialog.install): Minor refactoring, added JSDocs.
936         (WebInspector.GoToLineDialog._show): Added JSDocs and return value.
937         * inspector/front-end/Panel.js:
938         (WebInspector.Panel.prototype.handleShortcut):
939         Mark event as handled iff handler returned true.
940         * inspector/front-end/ScriptsPanel.js: Added return values to handlers.
941         * inspector/front-end/TimelinePanel.js: Ditto.
942
943 2013-03-06  Takashi Sakamoto  <tasak@google.com>
944
945         Box-shadow displayed improperly with border-radius.
946         https://bugs.webkit.org/show_bug.cgi?id=111256
947
948         Reviewed by Simon Fraser.
949
950         RoundedRect::adjustRadii doesn't adjust radii correctly, because
951         the method compares maxRadiusWidth with maxRadiusHeight. However,
952         we have to compare maxRadiusWidth / rect.width() with
953         maxRadiusHeight / rect.height().
954
955         Test: fast/borders/border-radius-with-box-shadow-01.html
956
957         * platform/graphics/RoundedRect.cpp:
958         (WebCore::RoundedRect::adjustRadii):
959         Should check which ratio is smaller.
960
961 2013-03-06  Mike West  <mkwst@chromium.org>
962
963         [V8] Preprocess constant values to avoid a "static_cast<signed int>" in CodeGeneratorV8.
964         https://bugs.webkit.org/show_bug.cgi?id=111625
965
966         Reviewed by Kentaro Hara.
967
968         When processing constants in IDL files, CodeGeneratorV8 currently runs
969         the values through 'static_cast<signed int>' in the generated code. We
970         can avoid this miniscule bit of overhead by preprocessing the hex value
971         in Perl when generating the code.
972
973         The FIXME has been in the code since it originally landed in 2009[1].
974         Now's as good a time as any to take care of it.
975
976         [1]: http://trac.webkit.org/browser/trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm?rev=144976#L2933
977
978         * bindings/scripts/CodeGeneratorV8.pm:
979         (GenerateImplementation):
980             If we're presented with a string which begins with '0x', run it
981             through some fairly obtuse Perlisms to first convert from a hex
982             string to an integer ('hex($value)'), "pack" the integer as an
983             unsigned integer ('pack("I", ...)'), and then "unpack" it as a
984             signed integer ('unpack("i", ...)'). Because that's _of course_
985             how you would do things.
986
987 2013-03-06  Paweł Forysiuk  <tuxator@o2.pl>
988
989         WebKit does not build without accelerated compositing after Changeset 144823
990         https://bugs.webkit.org/show_bug.cgi?id=111597
991
992         Reviewed by Kentaro Hara.
993
994         Properly guard functions ifdefed in ScrollingCoordinator.h.
995         Remove redundant checks and fallback code inside those functions.
996
997         * page/scrolling/ScrollingCoordinator.cpp:
998         (WebCore::ScrollingCoordinator::scrollLayerForScrollableArea):
999         (WebCore::ScrollingCoordinator::horizontalScrollbarLayerForScrollableArea):
1000         (WebCore::ScrollingCoordinator::verticalScrollbarLayerForScrollableArea):
1001         (WebCore):
1002
1003 2013-03-06  Hajime Morrita  <morrita@google.com>
1004
1005         Custom Elements Refactoring: CustomElementConstructor API shouldn't bound to HTMLElement
1006         https://bugs.webkit.org/show_bug.cgi?id=111678
1007
1008         Reviewed by Kentaro Hara.
1009
1010         The latest Custom Elements standard supports non-HTML custom elements. Even though current implementation
1011         support only HTML, it'd be better off to make API generic enough to support them.
1012
1013         This change
1014
1015         - eliminates HTMLElement from the API signature by replacing it with Element, and
1016         - rename V8HTMLCustomElement to V8CustomElement.
1017
1018         No new tests, just changing signatures and a class name.
1019
1020         * WebCore.gypi:
1021         * bindings/v8/V8CustomElement.cpp: Renamed from Source/WebCore/bindings/v8/V8HTMLCustomElement.cpp.
1022         (WebCore):
1023         (WebCore::findWrapperTypeOf):
1024         (WebCore::V8CustomElement::createWrapper):
1025         * bindings/v8/V8CustomElement.h: Renamed from Source/WebCore/bindings/v8/V8HTMLCustomElement.h.
1026         (WebCore):
1027         (V8CustomElement):
1028         (WebCore::V8CustomElement::toV8):
1029         (WebCore::V8CustomElement::wrap):
1030         (WebCore::HTMLCustomElement::wrap):
1031         * bindings/v8/custom/V8CustomElementConstructorCustom.cpp:
1032         (WebCore::V8CustomElementConstructor::callAsFunctionCallback):
1033         * dom/CustomElementConstructor.cpp:
1034         (WebCore::CustomElementConstructor::createElement):
1035         * dom/CustomElementConstructor.h:
1036         (WebCore):
1037         (CustomElementConstructor):
1038         * dom/CustomElementRegistry.cpp:
1039         (WebCore::CustomElementRegistry::constructorOf):
1040         (WebCore::CustomElementRegistry::createElement):
1041         * dom/CustomElementRegistry.h:
1042         (WebCore):
1043         (CustomElementRegistry):
1044         * dom/Document.cpp: Ensured that the document is an HTML.
1045         (WebCore::Document::registerElement):
1046         * dom/Document.idl:
1047         * dom/make_names.pl:
1048         (printWrapperFactoryCppFile):
1049         * html/HTMLDocument.idl: Moved an API to Document.idl
1050
1051 2013-03-06  Tim Horton  <timothy_horton@apple.com>
1052
1053         TileCache debug minimap should fit inside the intersection of the visible rect and exposed rect
1054         https://bugs.webkit.org/show_bug.cgi?id=111655
1055         <rdar://problem/13355773>
1056
1057         Reviewed by Simon Fraser.
1058
1059         If content clips to the exposed rect, make the TileCache minimap fit in the exposed rect too.
1060
1061         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1062         (WebCore::ScrollingCoordinatorMac::commitTreeState):
1063         * platform/graphics/TiledBacking.h:
1064         * platform/graphics/ca/mac/TileCache.mm:
1065         (WebCore::TileCache::updateTileCoverageMap):
1066
1067 2013-03-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1068
1069         Unreviewed, rolling out r144726.
1070         http://trac.webkit.org/changeset/144726
1071         https://bugs.webkit.org/show_bug.cgi?id=111681
1072
1073         caused performance regression for Dromaeo attribute tests.
1074         (Requested by arpitab on #webkit).
1075
1076         * dom/Element.h:
1077         (WebCore::ElementData::getAttributeItemIndex):
1078
1079 2013-03-04  Kinuko Yasuda  <kinuko@chromium.org>
1080
1081         File.lastModifiedDate() should return the current date/time if the file date/time is not available
1082         https://bugs.webkit.org/show_bug.cgi?id=111403
1083
1084         Reviewed by Kent Tamura.
1085
1086         Per the recent File API spec change:
1087         http://www.w3.org/TR/2012/WD-FileAPI-20121025/#dfn-lastModifiedDate
1088
1089         Test: http/tests/local/fileapi/script-tests/file-last-modified-after-delete.js:
1090
1091         * fileapi/File.cpp:
1092         (WebCore::File::lastModifiedDate): Changed to return the current date/time instead null if the valid file date/time is not available.
1093         * fileapi/File.h:
1094         (File):
1095
1096 2013-03-06  Philippe Liard  <pliard@chromium.org>
1097
1098         Make RuleData support up to 8191 selectors
1099         https://bugs.webkit.org/show_bug.cgi?id=111663
1100
1101         Reviewed by Andreas Kling.
1102
1103         r125294 made RuleData consume less memory by replacing a pointer with
1104         an index encoded on 12 bits.
1105         This unfortunately breaks Chrome for Android (and others) when a lot of
1106         CSS is used or more precisely when selectorIndex cannot be stored on 12
1107         bits.
1108
1109         Threfore this change decreases the number of bits used to store
1110         m_position by 1 (from 19 to 18) and adds this extra bit to
1111         m_selectorIndex so that values up to 8191 can be stored safely without
1112         overflowing.
1113
1114         * css/RuleSet.h:
1115         (RuleData):
1116
1117 2013-03-06  Seokju Kwon  <seokju.kwon@gmail.com>
1118
1119         Web Inspector: Remove unused code from contextmenu of element panel
1120         https://bugs.webkit.org/show_bug.cgi?id=111658
1121
1122         Reviewed by Pavel Feldman.
1123
1124         No new tests (no functional changes).
1125
1126         * inspector/front-end/ElementsPanel.js:
1127         (WebInspector.ElementsPanel.prototype._contextMenuEventFired.set get var):
1128         * inspector/front-end/ElementsTreeOutline.js:
1129         (WebInspector.ElementsTreeOutline.prototype.populateContextMenu):
1130
1131 2013-03-06  Julien Chaffraix  <jchaffraix@webkit.org>
1132
1133         [CSS Grid Layout] Extend our grammar to support 2 positions for grid-{row|column}
1134         https://bugs.webkit.org/show_bug.cgi?id=110777
1135
1136         Reviewed by Tony Chang.
1137
1138         Now that we support all the logical grid properties, we can change grid-{row|column}
1139         into shorthands. That's what this change does along with extending our parsing support
1140         to handle 2 positions.
1141
1142         Tests: fast/css-grid-layout/grid-item-column-row.html
1143                fast/css-grid-layout/grid-item-end-after-get-set.html
1144                fast/css-grid-layout/grid-item-start-before-get-set.html
1145
1146         * css/CSSComputedStyleDeclaration.cpp:
1147         Removed grid-{row|column} from computedProperties as they are shorthands (see comments
1148         at computedProperties definition).
1149
1150         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1151         (WebCore::CSSComputedStyleDeclaration::getCSSPropertyValuesForGridShorthand):
1152         Switched to using the StylePropertyShorthand and reusing the existing longhand code.
1153
1154         * css/CSSComputedStyleDeclaration.h:
1155         Added getCSSPropertyValuesForGridShorthand.
1156
1157         * css/CSSParser.cpp:
1158         (WebCore::CSSParser::parseValue):
1159         (WebCore::CSSParser::parseGridItemPositionShorthand):
1160         Added custom parsing for the shorthand, that builds on top of the longhand code.
1161
1162         * css/CSSParser.h:
1163         Added parseGridItemPositionShorthand.
1164
1165         * css/StyleResolver.cpp:
1166         (WebCore::StyleResolver::applyProperty):
1167         Removed the previous handling as shorthand are expanded at parse time.
1168
1169         * css/StylePropertySet.cpp:
1170         (WebCore::StylePropertySet::getPropertyValue):
1171         Added the new shorthands to the list.
1172
1173         * css/StylePropertyShorthand.cpp:
1174         (WebCore::webkitGridColumnShorthand):
1175         (WebCore::webkitGridRowShorthand):
1176         (WebCore::shorthandForProperty):
1177         * css/StylePropertyShorthand.h:
1178         Registered grid-{row|column} as shorthands.
1179
1180 2013-03-06  Kenneth Russell  <kbr@google.com>
1181
1182         [Chromium] Fix byte ordering bugs reading back WebGL canvases' content on Android
1183         https://bugs.webkit.org/show_bug.cgi?id=111661
1184
1185         Reviewed by James Robinson.
1186
1187         No new tests; covered by existing tests. Ran WebGL conformance
1188         tests on Android and desktop Linux to verify fix.
1189
1190         * platform/chromium/support/GraphicsContext3DChromium.cpp:
1191         (WebCore::GraphicsContext3D::paintRenderingResultsToImageData):
1192             Avoid incorrect byte swap on Android and other OSs which don't
1193             swizzle R and B channels.
1194
1195 2013-03-06  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1196
1197         [EFL] Improve warning messages when input value is out of range.
1198         https://bugs.webkit.org/show_bug.cgi?id=111534
1199
1200         Reviewed by Laszlo Gombos.
1201
1202         Show input value range when user inputs greater or less value.
1203
1204         * platform/efl/LocalizedStringsEfl.cpp:
1205         (WebCore::validationMessageRangeOverflowText):
1206         (WebCore::validationMessageRangeUnderflowText):
1207
1208 2013-03-06  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1209
1210         [EFL][WK2] Enable interactive form validation for email and url input type validation
1211         https://bugs.webkit.org/show_bug.cgi?id=111026
1212
1213         Reviewed by Laszlo Gombos.
1214
1215         WebKit EFL can check if input value is valid by enabling this feature.
1216
1217         * platform/efl/LocalizedStringsEfl.cpp: Change validation messages of email and url the same with chromium port.
1218         (WebCore::validationMessageTypeMismatchForEmailText):
1219         (WebCore::validationMessageTypeMismatchForMultipleEmailText):
1220         (WebCore::validationMessageTypeMismatchForURLText):
1221         * platform/efl/RenderThemeEfl.cpp: Add type checking conditions for email and url.
1222         (WebCore::RenderThemeEfl::supportsDataListUI):
1223
1224 2013-03-06  Aaron Colwell  <acolwell@chromium.org>
1225
1226         Remove WebCore::Node::isActiveNode() since it isn't called anywhere.
1227         https://bugs.webkit.org/show_bug.cgi?id=111646
1228
1229         Reviewed by Kentaro Hara.
1230
1231         No new tests. This removes dead code.
1232
1233         * dom/Node.h:
1234         (Node):
1235         * html/HTMLAudioElement.h:
1236
1237 2013-03-06  Abhishek Arya  <inferno@chromium.org>
1238
1239         Crash in SVGViewSpec::viewTarget
1240         https://bugs.webkit.org/show_bug.cgi?id=111648
1241
1242         Reviewed by Philip Rogers.
1243
1244         * svg/SVGViewSpec.cpp:
1245         (WebCore::SVGViewSpec::viewTarget):
1246
1247 2013-03-06  Benjamin Poulain  <benjamin@webkit.org>
1248
1249         WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
1250         https://bugs.webkit.org/show_bug.cgi?id=42696
1251
1252         Reviewed by Andreas Kling.
1253
1254         Since the method acts directly on a WebCore element and strictly test
1255         HTMLInputElement::shouldAutoComplete(), the test function is moved to internals.
1256
1257         * testing/Internals.cpp:
1258         (WebCore::Internals::elementShouldAutoComplete):
1259         * testing/Internals.h:
1260         * testing/Internals.idl:
1261
1262 2013-03-06  Alexey Proskuryakov  <ap@apple.com>
1263
1264         [Mac] Synthetic ResourceResponses cannot be sent over IPC without losing most information
1265         https://bugs.webkit.org/show_bug.cgi?id=111623
1266
1267         Reviewed by Brady Eidson.
1268
1269         * WebCore.exp.in: Exported functions for building synthetic responses.
1270
1271         * platform/network/ResourceResponseBase.cpp:
1272         * platform/network/ResourceResponseBase.h:
1273         Added a lot of FIXMEs.
1274
1275         * platform/network/cf/ResourceResponse.h:
1276         (WebCore::ResourceResponse::ResourceResponse):
1277         (WebCore::ResourceResponse::platformResponseIsUpToDate):
1278         Track m_platformResponseIsUpToDate flag as well as we can. Currently, it will
1279         be incorrect if a real platform response gets mutated.
1280
1281         * platform/network/cf/ResourceResponseCFNet.cpp:
1282         (WebCore::ResourceResponse::cfURLResponse): Added a FIXME about how useless this
1283         function is when it tries to create a new CFURLResponse.
1284
1285         * platform/network/mac/ResourceResponseMac.mm:
1286         (WebCore::ResourceResponse::initNSURLResponse): Added a FIXME.
1287         (WebCore::ResourceResponse::nsURLResponse): Added a return to make logic more clear.
1288         (WebCore::ResourceResponse::ResourceResponse): Track m_platformResponseIsUpToDate.
1289
1290         * platform/network/blackberry/ResourceResponse.h:
1291         * platform/network/curl/ResourceResponse.h:
1292         * platform/network/qt/ResourceResponse.h:
1293         * platform/network/soup/ResourceResponse.h:
1294         * platform/network/win/ResourceResponse.h:
1295         These platforms do not keep a platform response, so it's never up to date, and
1296         WebCore data needs to be serialized.
1297
1298 2013-03-06  Dana Jansens  <danakj@chromium.org>
1299
1300         [chromium] Remove WebSharedGraphicsContext3D class
1301         https://bugs.webkit.org/show_bug.cgi?id=111492
1302
1303         Reviewed by James Robinson.
1304
1305         Removing dead code, no new tests.
1306
1307         * WebCore.gypi:
1308         * platform/chromium/support/WebSharedGraphicsContext3D.cpp: Removed.
1309
1310 2013-03-06  Dana Jansens  <danakj@chromium.org>
1311
1312         [chromium] Don't get callbacks or create GrContext from unowned WebGraphicsContext3D
1313         https://bugs.webkit.org/show_bug.cgi?id=111638
1314
1315         Reviewed by James Robinson.
1316
1317         If the context is not owned, it's lifetime is not guaranteed, and by the time
1318         the GraphicsContext3D is destroyed, the WGC3D can already be deleted.
1319
1320         When the context is not owned by the GraphicsContext3D, then don't clean it up
1321         in the destructor or set up callbacks, as these are the owner's responsibility.
1322
1323         * platform/chromium/support/GraphicsContext3DPrivate.cpp:
1324         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
1325         (WebCore::GraphicsContext3DPrivate::grContext):
1326         (WebCore::GraphicsContext3DPrivate::setContextLostCallback):
1327         (WebCore::GraphicsContext3DPrivate::setErrorMessageCallback):
1328
1329 2013-02-22  Jer Noble  <jer.noble@apple.com>
1330
1331         Default mouse cursor behavior should be auto-hide for full screen video with custom controls
1332         https://bugs.webkit.org/show_bug.cgi?id=107601
1333
1334         Reviewed by Beth Dakin.
1335
1336         Test: fullscreen/video-cursor-auto-hide.html
1337
1338         To facilitate automatically hiding the mouse cursor after a certain amount of idle mouse
1339         time, add a new CSS property '-webkit-cursor-visibility', and handle that value inside of
1340         EventHandler. When that value is present, the EventHandler will start a timer which, when
1341         fired, will set the view's cursor to the None cursor. Subsequent mouse moves will either
1342         cancel the timer, or reset the auto-hide timer.
1343
1344         Add a new CSS property, '-webkit-cursor-visibility':
1345         * css/CSSComputedStyleDeclaration.cpp:
1346         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1347         * css/CSSParser.cpp:
1348         (WebCore::CSSParser::parseValue):
1349         * css/CSSPrimitiveValueMappings.h:
1350         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1351         (WebCore::CSSPrimitiveValue::operator ECursorVisibility):
1352         * css/CSSProperty.cpp:
1353         (WebCore::CSSProperty::isInheritedProperty):
1354         * css/CSSPropertyNames.in:
1355         * css/CSSValueKeywords.in:
1356         * css/StyleBuilder.cpp:
1357         (WebCore::StyleBuilder::StyleBuilder):
1358         * css/StyleResolver.cpp:
1359         (WebCore::StyleResolver::applyProperty):
1360
1361         Add a rule for video descendants of full screen elements to auto-hide the cursor on hover:
1362         * css/fullscreen.css:
1363         (:-webkit-full-screen video:hover):
1364
1365         Add a new timer, m_autoHideCursorTimer, to control resetting the view's cursor to None after
1366         enough mouse idle time has passed.
1367         * page/EventHandler.cpp:
1368         (WebCore::EventHandler::EventHandler):
1369         (WebCore::EventHandler::~EventHandler):
1370         (WebCore::EventHandler::clear):
1371         (WebCore::EventHandler::selectCursor):
1372         (WebCore::EventHandler::startAutoHideCursorTimer):
1373         (WebCore::EventHandler::cancelAutoHideCursorTimer):
1374         (WebCore::EventHandler::autoHideCursorTimerFired):
1375         * page/EventHandler.h:
1376
1377         Make FrameView::isActive() a public function (like it is in its superclass).
1378         * page/FrameView.h:
1379         (FrameView):
1380
1381         Move the definition for timeWithoutMouseMovementBeforeHidingControls from page->theme()
1382         to page->settings() and allow that setting to be overridden in InternalSettings for 
1383         testing purposes:
1384         * page/Settings.cpp:
1385         (WebCore::Settings::Settings):
1386         * page/Settings.h:
1387         (WebCore::Settings::setTimeWithoutMouseMovementBeforeHidingControls):
1388         (WebCore::Settings::timeWithoutMouseMovementBeforeHidingControls):
1389         * rendering/RenderTheme.h:
1390         * testing/InternalSettings.cpp:
1391         (WebCore::InternalSettings::Backup::Backup):
1392         (WebCore::InternalSettings::Backup::restoreTo):
1393         (WebCore::InternalSettings::setTimeWithoutMouseMovementBeforeHidingControls):
1394         * testing/InternalSettings.h:
1395         (InternalSettings):
1396         * testing/InternalSettings.idl:
1397         * html/shadow/MediaControls.cpp:
1398         (WebCore::MediaControls::startHideFullscreenControlsTimer):
1399
1400         Add support to FeatureObserver for CURSOR_VISIBILITY:
1401         * page/FeatureObserver.h:
1402
1403         Enable the feature flag:
1404         * Configurations/FeatureDefines.xcconfig:
1405
1406 2013-03-06  Jer Noble  <jer.noble@apple.com>
1407
1408         Full screen from an iframe with a z-index style will allow siblings with higher z-index to overlay full screen content.
1409         https://bugs.webkit.org/show_bug.cgi?id=111637
1410
1411         Reviewed by Simon Fraser.
1412
1413         No new tests; updated fullscreen/full-screen-iframe-zIndex.html to expose bug.
1414
1415         Pages with explicit z-index: styles on their iframes will override the default z-index: UA style when
1416         elements within that iframe enter full screen mode. Mark the UA style as !important so as to not allow
1417         iframe siblings with higher z-index styles to overlay the full screen element.
1418
1419         * css/fullscreen.css:
1420         (:-webkit-full-screen):
1421
1422 2013-03-06  Levi Weintraub  <leviw@chromium.org>
1423
1424         InsertUnorderedList can lead to lost content and assertions in moveParagraphs
1425         https://bugs.webkit.org/show_bug.cgi?id=111228
1426
1427         Reviewed by Ryosuke Niwa.
1428
1429         When a list is wrapped in a presentational inline like a b tag, we'd create markup that included
1430         everything up to the b tag from moveParagraphs when intending to only move the contents of the
1431         list item. This could make it impossible to remove content from a list and trigger loss of
1432         editable text.
1433
1434         Test: editing/execCommand/insert-remove-block-list-inside-presentational-inline.html
1435
1436         * editing/EditingStyle.cpp:
1437         (WebCore::elementMatchesAndPropertyIsNotInInlineStyleDecl): Ensure there's an inline style
1438         before calling propertyExistsInStyle.
1439         (WebCore::HTMLElementEquivalent::propertyExistsInStyle): Removing null check for style.
1440         All callers ensure this value isn't null.
1441         * editing/markup.cpp:
1442         (WebCore::highestAncestorToWrapMarkup): Avoid going over RenderBlocks when finding the highest
1443         presentational ancestor to avoid leaving the bounds of the original paragraph.
1444
1445 2013-03-06  Adam Klein  <adamk@chromium.org>
1446
1447         [V8] Use implicit references instead of object groups to keep registered MutationObservers alive
1448         https://bugs.webkit.org/show_bug.cgi?id=111382
1449
1450         Reviewed by Adam Barth.
1451
1452         Two-phase approach to implicit references: after grouping objects
1453         together, add an implicit reference between each registered node's
1454         group and the MutationObserver's group (which includes wrappers from
1455         all worlds).
1456
1457         Also changed many uses of v8::Value to v8::Object where we know we're
1458         dealing with Object and the V8 API expects them.
1459
1460         Test: ManualTests/mutation-observer-leaks-nodes.html
1461
1462         * bindings/v8/V8GCController.cpp:
1463         (WebCore::ImplicitConnection::ImplicitConnection):
1464         (WebCore::ImplicitConnection::wrapper):
1465         (ImplicitConnection):
1466         (WebCore::ImplicitReference::ImplicitReference): Wrapper class holding a parent who should have an implicit reference to a child.
1467         (ImplicitReference):
1468         (WebCore::operator<): Needed for std::sort() call to avoid the overhead of using a HashMap
1469         (WebCore::WrapperGrouper::addObjectWrapperToGroup):
1470         (WebCore::WrapperGrouper::addNodeWrapperToGroup):
1471         (WebCore::WrapperGrouper::addImplicitReference):
1472         (WrapperGrouper):
1473         (WebCore::WrapperGrouper::apply):
1474
1475 2013-03-06  Ankur Taly  <ataly@google.com>
1476
1477         Modify log method in V8DOMActivityLogger so that the apiName and
1478         extraInfo arguments are of type const String& instead of const char*.
1479         This change gets rid of some of the memory ownership issues that arise
1480         with char* pointers.
1481         https://bugs.webkit.org/show_bug.cgi?id=111483
1482
1483         Reviewed by Adam Barth.
1484
1485         There are no new tests as there is no change in behavior.
1486
1487         * bindings/v8/V8DOMActivityLogger.h:
1488         (WebCore::V8DOMActivityLogger::log):
1489
1490 2013-03-06  Mike Reed  <reed@google.com>
1491
1492         Use SkTypeface API directly, rather than (soon to be private) SkFontHost
1493         https://bugs.webkit.org/show_bug.cgi?id=111588
1494
1495         Reviewed by Stephen White.
1496
1497         No new tests, as existing tests in fast/writing-mode exercise this code.
1498
1499         e.g. japanese-rl-text-with-broken-font.html
1500              vertical-subst-font-vert-no-dflt.html
1501
1502         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp:
1503         (WebCore::FontPlatformData::emSizeInFontUnits):
1504         (WebCore::FontPlatformData::openTypeTable):
1505         * platform/graphics/harfbuzz/HarfBuzzFaceSkia.cpp:
1506         (WebCore::harfBuzzSkiaGetTable):
1507         (WebCore::HarfBuzzFace::createFace):
1508         * platform/graphics/skia/SimpleFontDataSkia.cpp:
1509         (WebCore::SimpleFontData::platformInit):
1510
1511 2013-03-06  Victor Costan <costan@gmail.com>
1512
1513         Cleanup in multipart FormData sending code.
1514         https://bugs.webkit.org/show_bug.cgi?id=111603
1515
1516         Reviewed by Alexey Proskuryakov.
1517
1518         No new tests. This is cleanup.
1519
1520         * platform/network/FormDataBuilder.cpp:
1521         (WebCore::appendQuotedString): use proper types (e.g, size_t instead of
1522         unsigned long)
1523
1524 2013-03-06  Tony Gentilcore  <tonyg@chromium.org>
1525
1526         Threaded HTML parser should use 8 bit strings for attributes
1527         https://bugs.webkit.org/show_bug.cgi?id=111610
1528
1529         Reviewed by Eric Seidel.
1530
1531         This fixes a 27% regression in dromaeo_jslibattrjquery on the threaded HTML parser vs. the main thread parser.
1532
1533         No new tests because no new functionality.
1534
1535         * html/parser/CompactHTMLToken.cpp:
1536         (WebCore::CompactHTMLToken::CompactHTMLToken):
1537
1538 2013-03-06  Alpha Lam  <hclam@chromium.org>
1539
1540         More cleanup in GIFImageReader
1541         https://bugs.webkit.org/show_bug.cgi?id=111137
1542
1543         Reviewed by Stephen White.
1544
1545         Refactor GIFImageReaderReader with the following changes:
1546         + Separate GIFLZWContext for decoding states.
1547         + Replace unsigned char* with Vector<unsigned char>
1548
1549         There is no change in code behavior and just refactoring.
1550
1551         No new tests. This is covered by existing GIFImageReaderTest.
1552         I also did a local testing on a 50k image corpus and showed no regression.
1553
1554         * platform/image-decoders/gif/GIFImageDecoder.cpp:
1555         (WebCore::GIFImageDecoder::haveDecodedRow):
1556         * platform/image-decoders/gif/GIFImageDecoder.h:
1557         (GIFImageDecoder):
1558         * platform/image-decoders/gif/GIFImageReader.cpp:
1559         (GIFImageReader::outputRow):
1560         (GIFImageReader::doLZW):
1561         (GIFImageReader::decodeInternal):
1562         (GIFImageReader::prepareLZWContext):
1563         * platform/image-decoders/gif/GIFImageReader.h:
1564         (GIFFrameContext):
1565         (GIFFrameContext::GIFFrameContext):
1566         (GIFFrameContext::~GIFFrameContext):
1567         (GIFLZWContext):
1568         (GIFLZWContext::GIFLZWContext):
1569         (GIFImageReader):
1570
1571 2013-03-06  Tim Horton  <timothy_horton@apple.com>
1572
1573         Fix typo'd MainThreadScrollingBecauseOfStyleIndictaion
1574         https://bugs.webkit.org/show_bug.cgi?id=111557
1575
1576         Reviewed by Geoff Garen.
1577
1578         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1579         (WebCore::ScrollingCoordinatorMac::commitTreeState):
1580         * platform/graphics/TiledBacking.h:
1581         * platform/graphics/ca/mac/TileCache.mm:
1582         (WebCore::TileCache::updateTileCoverageMap):
1583
1584 2013-03-05  Geoffrey Garen  <ggaren@apple.com>
1585
1586         Removed some dead code in the page cache
1587         https://bugs.webkit.org/show_bug.cgi?id=111525
1588
1589         Reviewed by Alexey Proskuryakov.
1590
1591         Page cache autorelease doesn't exist anymore, so there's no need to keep
1592         around these olds hacks.
1593
1594         * WebCore.exp.in:
1595         * history/PageCache.cpp:
1596         (WebCore::PageCache::PageCache):
1597         (WebCore):
1598         * history/PageCache.h:
1599         (PageCache):
1600         * page/Settings.cpp:
1601         (WebCore::Settings::setUsesPageCache):
1602         * platform/mac/MemoryPressureHandlerMac.mm:
1603         (WebCore::MemoryPressureHandler::releaseMemory):
1604         * platform/qt/QtTestSupport.cpp:
1605         (WebKit::QtTestSupport::clearMemoryCaches):
1606
1607 2013-03-06  Rafael Weinstein  <rafaelw@chromium.org>
1608
1609         Unreviewed, rolling out r144924.
1610         http://trac.webkit.org/changeset/144924
1611         https://bugs.webkit.org/show_bug.cgi?id=109908
1612
1613         caused multiple crashes in inspector/debugger tests
1614
1615         * bindings/js/JSInjectedScriptHostCustom.cpp:
1616         * bindings/js/ScriptObject.h:
1617         * bindings/v8/ScriptObject.h:
1618         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1619         * inspector/InjectedScriptHost.cpp:
1620         (WebCore::InjectedScriptHost::create):
1621         (WebCore::InjectedScriptHost::InjectedScriptHost):
1622         (WebCore::InjectedScriptHost::disconnect):
1623         * inspector/InjectedScriptHost.h:
1624         (WebCore):
1625         (InjectedScriptHost):
1626         * inspector/InjectedScriptHost.idl:
1627         * inspector/InjectedScriptManager.cpp:
1628         (WebCore::InjectedScriptManager::InjectedScriptManager):
1629         (WebCore::InjectedScriptManager::discardInjectedScripts):
1630         (WebCore::InjectedScriptManager::discardInjectedScriptsFor):
1631         * inspector/InjectedScriptManager.h:
1632         (InjectedScriptManager):
1633         * inspector/InjectedScriptSource.js:
1634         (.):
1635
1636 2013-03-06  Dmitry Zvorygin  <zvorygin@chromium.org>
1637
1638         Introduce new message sources for logging.
1639         https://bugs.webkit.org/show_bug.cgi?id=110968
1640
1641         Reviewed by Pavel Feldman.
1642
1643         Added SecurityMessageSource, RenderingMessageSource, StorageMessageSource, AppCacheMessageSource, CSSMessageSource.
1644         Changed some logging lines to contain more descriptive message source.
1645
1646         * Modules/webdatabase/DatabaseBase.cpp:
1647         (WebCore::DatabaseBase::logErrorMessage):
1648         * Modules/webdatabase/DatabaseManager.cpp:
1649         (WebCore::DatabaseManager::logErrorMessage):
1650         * Modules/websockets/WebSocketChannel.cpp:
1651         (WebCore::WebSocketChannel::fail):
1652         * bindings/ScriptControllerBase.cpp:
1653         (WebCore::ScriptController::canExecuteScripts):
1654         * css/MediaList.cpp:
1655         (WebCore::addResolutionWarningMessageToConsole):
1656         * dom/Document.cpp:
1657         (WebCore::Document::processHttpEquiv):
1658         * dom/ScriptElement.cpp:
1659         (WebCore::ScriptElement::executeScript):
1660         (WebCore::ScriptElement::notifyFinished):
1661         * dom/ViewportArguments.cpp:
1662         (WebCore::reportViewportWarning):
1663         * html/HTMLFormControlElement.cpp:
1664         (WebCore::shouldAutofocus):
1665         * html/HTMLFormElement.cpp:
1666         (WebCore::HTMLFormElement::validateInteractively):
1667         * html/HTMLIFrameElement.cpp:
1668         (WebCore::HTMLIFrameElement::parseAttribute):
1669         * html/canvas/CanvasRenderingContext2D.cpp:
1670         (WebCore::CanvasRenderingContext2D::getImageData):
1671         * html/canvas/WebGLRenderingContext.cpp:
1672         (WebCore):
1673         (WebCore::WebGLRenderingContext::printWarningToConsole):
1674         * html/parser/XSSAuditor.cpp:
1675         (WebCore::XSSAuditor::init):
1676         * html/parser/XSSAuditorDelegate.cpp:
1677         (WebCore::XSSAuditorDelegate::didBlockScript):
1678         * inspector/ConsoleMessage.cpp:
1679         (WebCore::messageSourceValue):
1680         * inspector/Inspector.json:
1681         * loader/FrameLoader.cpp:
1682         (WebCore::FrameLoader::submitForm):
1683         (WebCore::FrameLoader::reportLocalLoadFailed):
1684         (WebCore::createWindow):
1685         * loader/ImageLoader.cpp:
1686         (WebCore::ImageLoader::notifyFinished):
1687         * loader/MainResourceLoader.cpp:
1688         (WebCore::MainResourceLoader::responseReceived):
1689         * loader/MixedContentChecker.cpp:
1690         (WebCore::MixedContentChecker::logWarning):
1691         * loader/TextTrackLoader.cpp:
1692         (WebCore::TextTrackLoader::corsPolicyPreventedLoad):
1693         * loader/appcache/ApplicationCacheGroup.cpp:
1694         (WebCore::ApplicationCacheGroup::abort):
1695         * loader/cache/CachedResourceLoader.cpp:
1696         (WebCore::CachedResourceLoader::printAccessDeniedMessage):
1697         * page/Console.cpp:
1698         (WebCore::printMessageSourceAndLevelPrefix):
1699         * page/ConsoleTypes.h:
1700         * page/ContentSecurityPolicy.cpp:
1701         (WebCore::ContentSecurityPolicy::logToConsole):
1702         * page/DOMWindow.cpp:
1703         (WebCore::DOMWindow::dispatchMessageEventWithOriginCheck):
1704         * page/PointerLockController.cpp:
1705         (WebCore::PointerLockController::requestPointerLock):
1706         * svg/SVGDocumentExtensions.cpp:
1707         (WebCore::reportMessage):
1708
1709 2013-03-06  Florin Malita  <fmalita@chromium.org>
1710
1711         SVG pattern to pattern reference does not work if first pattern has a child node
1712         https://bugs.webkit.org/show_bug.cgi?id=111586
1713
1714         Reviewed by Philip Rogers.
1715
1716         SVGPatternElement::collectPatternAttributes should test for child elements, not child nodes.
1717
1718         Tests: svg/custom/pattern-reference-expected.svg
1719                svg/custom/pattern-reference.svg
1720
1721         * svg/SVGPatternElement.cpp:
1722         (WebCore::SVGPatternElement::collectPatternAttributes):
1723
1724 2013-03-06  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1725
1726         [soup] session cookies are not correctly reported in getRawCookies()
1727         https://bugs.webkit.org/show_bug.cgi?id=111584
1728
1729         Reviewed by Martin Robinson.
1730
1731         As per libsoup documentation, SoupCookie->expires is NULL for session cookies.
1732         However, the soup implementation for getRawCookies() does not check for NULL
1733         case before passing the value to soup_date_to_time_t(), which leads to run time
1734         warnings.
1735
1736         We should also pass true for WebCore::Cookie's session argument if
1737         SoupCookie->expires is NULL. The current implementation reports the cookie as a
1738         session one if soup_cookie_jar_is_persistent(jar) returns true, which is
1739         inaccurate.
1740
1741         No new tests, no behavior change for layout tests as Web Inspector currently
1742         ignores the "session" member and uses expires/max-age instead to deduce it.
1743
1744         * platform/network/soup/CookieJarSoup.cpp:
1745         (WebCore::getRawCookies):
1746
1747 2013-03-06  Douglas Stockwell  <dstockwell@chromium.org>
1748
1749         REGRESSION(r111639): delayed animation start can be postponed
1750         https://bugs.webkit.org/show_bug.cgi?id=108582
1751
1752         Query the animation timer directly for the time it will next fire rather than
1753         trying to cache the interval. Previous approach was incorrect -- as time advanced
1754         it was possible for the interval to jump beyond the next service time.
1755
1756         Reviewed by Darin Adler.
1757
1758         Test: animations/animation-delay-changed.html
1759
1760         * page/animation/AnimationController.cpp:
1761         (WebCore::AnimationControllerPrivate::AnimationControllerPrivate):
1762         (WebCore::AnimationControllerPrivate::updateAnimationTimerForRenderer):
1763         (WebCore::AnimationControllerPrivate::updateAnimationTimer):
1764         * page/animation/AnimationControllerPrivate.h:
1765         (AnimationControllerPrivate): Remove m_previousTimeToNextService
1766
1767 2013-03-06  Andrey Lushnikov  <lushnikov@chromium.org>
1768
1769         Web Inspector: [ACE] show execution line in Ace editor
1770         https://bugs.webkit.org/show_bug.cgi?id=111575
1771
1772         Reviewed by Pavel Feldman.
1773
1774         Highlight execution line by the means of Ace full line markers.
1775
1776         No new tests.
1777
1778         * inspector/front-end/AceTextEditor.js:
1779         (WebInspector.AceTextEditor.prototype.setExecutionLine):
1780         (WebInspector.AceTextEditor.prototype.clearExecutionLine):
1781         (WebInspector.AceTextEditor.prototype.setSelection):
1782         * inspector/front-end/ace/acedevtools.css:
1783         (.ace-editor-container):
1784         (.webkit-execution-line):
1785
1786 2013-03-06  Yury Semikhatsky  <yurys@chromium.org>
1787
1788         Web Inspector: fix closure compiler warnings in the profiler code
1789         https://bugs.webkit.org/show_bug.cgi?id=111581
1790
1791         Reviewed by Vsevolod Vlasov.
1792
1793         Added missing annotations. Replaced NativeProfileLauncherView with
1794         ProfileLauncherView.
1795
1796         * inspector/InjectedScriptExterns.js:
1797         (InjectedScriptHost.prototype.objectId):
1798         (InjectedScriptHost.prototype.releaseObjectId):
1799         * inspector/front-end/FlameChart.js:
1800         (WebInspector.FlameChart.prototype._forEachNode):
1801         * inspector/front-end/ProfileLauncherView.js:
1802         * inspector/front-end/ProfilesPanel.js:
1803
1804 2013-03-06  Carlos Garcia Campos  <cgarcia@igalia.com>
1805
1806         [BlackBerry] Pass String::StrictConversion instead of true to String::utf8()
1807         https://bugs.webkit.org/show_bug.cgi?id=111546
1808
1809         Reviewed by Rob Buis.
1810
1811         String::utf8() API changed in r134173.
1812
1813         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
1814         (WebCore::MediaPlayerPrivate::notifyChallengeResult):
1815
1816 2013-03-06  Julien Chaffraix  <jchaffraix@webkit.org>
1817
1818         Remove the (dead) code for handling shorthands in StyleResolver / StyleBuilder
1819         https://bugs.webkit.org/show_bug.cgi?id=111505
1820
1821         Unreviewed minimal build fix.
1822
1823         * css/StyleResolver.cpp:
1824         (WebCore::StyleResolver::applyProperty):
1825         Put CSSPropertyWebkitWrap under the proper if-guard.
1826
1827 2013-03-06  Vsevolod Vlasov  <vsevik@chromium.org>
1828
1829         Unreviewed follow up to r144928: front-end closure compilation fixes.
1830
1831         * inspector/front-end/FilteredItemSelectionDialog.js:
1832         (WebInspector.JavaScriptOutlineDialog.prototype.dispose):
1833         (WebInspector.OpenResourceDialog.prototype.dispose):
1834         * inspector/front-end/StyleSheetOutlineDialog.js:
1835         (WebInspector.StyleSheetOutlineDialog.prototype.dispose):
1836
1837 2013-03-06  Vsevolod Vlasov  <vsevik@chromium.org>
1838
1839         Web Inspector: Update open resource dialog when new uiSourceCodes are loaded.
1840         https://bugs.webkit.org/show_bug.cgi?id=111327
1841
1842         Reviewed by Pavel Feldman.
1843
1844         * inspector/front-end/FilteredItemSelectionDialog.js:
1845         (WebInspector.FilteredItemSelectionDialog):
1846         (WebInspector.FilteredItemSelectionDialog.prototype.willHide):
1847         (WebInspector.FilteredItemSelectionDialog.prototype._itemsLoaded):
1848         (WebInspector.FilteredItemSelectionDialog.prototype._updateAfterItemsLoaded):
1849         (WebInspector.FilteredItemSelectionDialog.prototype._filterItems.compareFunction):
1850         (WebInspector.FilteredItemSelectionDialog.prototype._filterItems):
1851         (WebInspector.SelectionDialogContentProvider.prototype.dispose):
1852         (WebInspector.JavaScriptOutlineDialog.prototype._didBuildOutlineChunk):
1853         (WebInspector.OpenResourceDialog):
1854         (WebInspector.OpenResourceDialog.prototype.requestItems):
1855         (WebInspector.OpenResourceDialog.prototype._filterUISourceCode):
1856         (WebInspector.OpenResourceDialog.prototype._uiSourceCodeAdded):
1857         (WebInspector.OpenResourceDialog.prototype.dispose):
1858         * inspector/front-end/StyleSheetOutlineDialog.js:
1859         (WebInspector.StyleSheetOutlineDialog.prototype.requestItems):
1860         (WebInspector.StyleSheetOutlineDialog.prototype.requestItems.didGetStyleSheet):
1861
1862 2013-03-06  Vladislav Kaznacheev  <kaznacheev@chromium.org>
1863
1864         Web Inspector: Move sidebar-specific styles to a separate file.
1865         https://bugs.webkit.org/show_bug.cgi?id=111173
1866
1867         Reviewed by Pavel Feldman.
1868
1869         * WebCore.gypi:
1870         * inspector/front-end/BreakpointsSidebarPane.js:
1871         (WebInspector.JavaScriptBreakpointsSidebarPane):
1872         (WebInspector.EventListenerBreakpointsSidebarPane):
1873         * inspector/front-end/NativeBreakpointsSidebarPane.js:
1874         (WebInspector.NativeBreakpointsSidebarPane):
1875         * inspector/front-end/SidebarPane.js:
1876         (WebInspector.SidebarPaneTitle):
1877         (WebInspector.SidebarPaneStack):
1878         (WebInspector.SidebarTabbedPane):
1879         * inspector/front-end/WebKit.qrc:
1880         * inspector/front-end/breakpointsList.css: Added.
1881         (.sidebar-pane > .body .breakpoint-condition):
1882         (#breakpoint-condition-input):
1883         (ol.breakpoint-list):
1884         (.breakpoints-list-deactivated):
1885         (.breakpoint-list li):
1886         (.breakpoint-list li:hover):
1887         (.breakpoint-list .checkbox-elem):
1888         (.breakpoint-list .source-text):
1889         (.sidebar-pane .breakpoint-hit):
1890         (li.breakpoint-hit .breakpoint-hit-marker):
1891         (.event-listener-breakpoints .event-category):
1892         (.event-listener-breakpoints.properties-tree .children li):
1893         (.event-listener-breakpoints .checkbox-elem):
1894         * inspector/front-end/elementsPanel.css:
1895         (.panel.elements .sidebar-pane-toolbar > select):
1896         (.panel.elements .sidebar-pane-toolbar > select:hover):
1897         (.panel.elements .sidebar-pane-toolbar > select:active):
1898         (.panel.elements .sidebar-pane-toolbar > select.select-settings):
1899         (.panel.elements .sidebar-pane-toolbar > select.select-filter):
1900         (.panel.elements .sidebar-pane-toolbar > select > option, .panel.elements .sidebar-pane-toolbar > select > hr):
1901         * inspector/front-end/inspector.css:
1902         (.event-bar .event-properties):
1903         * inspector/front-end/scriptsPanel.css:
1904         (.workers-list > li):
1905         (a.worker-item):
1906         (a.worker-item:hover):
1907         * inspector/front-end/sidebarPane.css: Added.
1908         (.sidebar-pane):
1909         (.sidebar-pane > .body):
1910         (.sidebar-pane > .body .info):
1911         (.sidebar-pane > .body .placard + .info):
1912         (.sidebar-pane.visible > .body):
1913         (.sidebar-pane .section .properties):
1914         (.sidebar-tabbed-pane .tabbed-pane-header):
1915         (.sidebar-pane-stack > .sidebar-pane.visible:nth-last-of-type(1)):
1916         (.sidebar-pane-title):
1917         (.sidebar-pane-title + .sidebar-pane-title, .pane:not(.visible) + .sidebar-pane-title, .sidebar-pane-title:first-of-type):
1918         (.sidebar-pane-title:active):
1919         (.sidebar-pane-title::before):
1920         (.sidebar-pane-title.expanded::before):
1921         (.sidebar-pane-toolbar):
1922         (.sidebar-pane-toolbar > *):
1923         (.sidebar-pane-toolbar > .pane-title-button):
1924         (.sidebar-pane-toolbar > .pane-title-button:hover):
1925         (.sidebar-pane-toolbar > .pane-title-button:active, .sidebar-pane-toolbar > .pane-title-button.toggled):
1926         (.sidebar-pane-toolbar > .pane-title-button.add):
1927         (.sidebar-pane-toolbar > .pane-title-button.element-state):
1928         (.sidebar-pane-toolbar > .pane-title-button.refresh):
1929         (.sidebar-pane-subtitle):
1930         (body.platform-windows .sidebar-pane-subtitle):
1931         (.sidebar-pane-subtitle input, .section .header input[type=checkbox]):
1932
1933 2013-03-06  Vladislav Kaznacheev  <kaznacheev@chromium.org>
1934
1935         Web Inspector: Combine style-related panes into a single tab when Elements panel is split horizontally.
1936         https://bugs.webkit.org/show_bug.cgi?id=111550
1937         Reviewed by Pavel Feldman.
1938
1939         Grouping the Elements sidebar panes into two tabbed panes proved to be
1940         confusing and inconvenient. Put all the Elements sidebar panes into a single tabbed pane.
1941         Combined Styles, Computed Style and Metrics into a single pane.
1942
1943         * inspector/front-end/ElementsPanel.js:
1944         (WebInspector.ElementsPanel.prototype._splitVertically):
1945         (WebInspector.ElementsPanel.prototype.addExtensionSidebarPane):
1946         * inspector/front-end/elementsPanel.css:
1947         (.sidebar-pane.composite):
1948         (.sidebar-pane.composite > .body):
1949         (.sidebar-pane.composite .metrics):
1950         (.sidebar-pane.composite .sidebar-pane-toolbar):
1951         (.sidebar-pane.composite .sidebar-pane-toolbar > .sidebar-pane-subtitle):
1952         (.sidebar-pane.composite .styles-section.read-only):
1953
1954 2013-03-05  Yury Semikhatsky  <yurys@chromium.org>
1955
1956         Web Inspector: support stable remote object ids
1957         https://bugs.webkit.org/show_bug.cgi?id=109908
1958
1959         Reviewed by Pavel Feldman.
1960
1961         Introduced a map from javascript object to its id. It guarantees
1962         that object is assined id only once (unless it is explicitely
1963         released). The map is per execution context and is stored in
1964         InjectedScriptManager.
1965
1966         Test: inspector-protocol/persistent-id.html
1967
1968         * bindings/js/JSInjectedScriptHostCustom.cpp:
1969         (WebCore::JSInjectedScriptHost::objectId):
1970         (WebCore):
1971         (WebCore::JSInjectedScriptHost::releaseObjectId):
1972         * bindings/js/ScriptObject.h:
1973         (WTF):
1974         (WTF::ScriptObjectHash::hash):
1975         (WTF::ScriptObjectHash::equal):
1976         (ScriptObjectHash):
1977         * bindings/v8/ScriptObject.h:
1978         (WTF):
1979         (WTF::ScriptObjectHash::hash):
1980         (WTF::ScriptObjectHash::equal):
1981         (ScriptObjectHash):
1982         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1983         (WebCore::V8InjectedScriptHost::objectIdMethodCustom):
1984         (WebCore):
1985         (WebCore::V8InjectedScriptHost::releaseObjectIdMethodCustom):
1986         * inspector/InjectedScriptHost.cpp:
1987         (WebCore::InjectedScriptHost::create):
1988         (WebCore::InjectedScriptHost::InjectedScriptHost):
1989         (WebCore::InjectedScriptHost::disconnect):
1990         (WebCore::InjectedScriptHost::objectId):
1991         (WebCore):
1992         (WebCore::InjectedScriptHost::releaseObjectId):
1993         * inspector/InjectedScriptHost.h:
1994         (WebCore):
1995         (InjectedScriptHost):
1996         * inspector/InjectedScriptHost.idl:
1997         * inspector/InjectedScriptManager.cpp:
1998         (InjectedScriptManager::ObjectIdMap):
1999         (WebCore::InjectedScriptManager::ObjectIdMap::ObjectIdMap):
2000         (WebCore::InjectedScriptManager::ObjectIdMap::objectId):
2001         (WebCore::InjectedScriptManager::ObjectIdMap::releaseObjectId):
2002         (WebCore):
2003         (WebCore::InjectedScriptManager::InjectedScriptManager):
2004         (WebCore::InjectedScriptManager::discardInjectedScripts):
2005         (WebCore::InjectedScriptManager::discardInjectedScriptsFor):
2006         (WebCore::InjectedScriptManager::objectId):
2007         (WebCore::InjectedScriptManager::releaseObjectId):
2008         * inspector/InjectedScriptManager.h:
2009         (InjectedScriptManager):
2010         * inspector/InjectedScriptSource.js:
2011         (.):
2012
2013 2013-03-06  Marja Hölttä  <marja@chromium.org>
2014
2015         REGRESSION(r144617): Wrong usage of overwritten variable in toDOMWindow (V8Binding.cpp)
2016         https://bugs.webkit.org/show_bug.cgi?id=111565
2017
2018         Reviewed by Jochen Eisinger.
2019
2020         In toDOMWindow, the variable "global" was first nuked, and then used again. This
2021         change was introduced in r144617.
2022
2023         No new tests (no functional changes).
2024
2025         * bindings/v8/V8Binding.cpp:
2026         (WebCore::toDOMWindow):
2027
2028 2013-03-06  Yury Semikhatsky  <yurys@chromium.org>
2029
2030         Web Inspector: use regular eval instead of injectScript for front-end extension API
2031         https://bugs.webkit.org/show_bug.cgi?id=111529
2032
2033         Reviewed by Pavel Feldman.
2034
2035         Removed InjectedScriptManager::injectScript and replaced all of it calls
2036         except the actual script injection with ScriptController::executeScript.
2037
2038         * inspector/InjectedScriptManager.cpp:
2039         (WebCore::InjectedScriptManager::injectedScriptFor):
2040         * inspector/InjectedScriptManager.h:
2041         (InjectedScriptManager):
2042         * inspector/InspectorAgent.cpp:
2043         (WebCore::InspectorAgent::didClearWindowObjectInWorld):
2044         * inspector/InspectorPageAgent.cpp:
2045         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
2046         * inspector/front-end/DOMAgent.js:
2047         (WebInspector.DOMAgent.prototype._emulateTouchEventsChanged.get if):
2048         * inspector/front-end/ExtensionAPI.js:
2049         (buildExtensionAPIInjectedScript):
2050         * inspector/front-end/ExtensionServer.js:
2051         (WebInspector.ExtensionServer.prototype._onReload):
2052
2053 2013-03-06  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2054
2055         [Qt] Do not disable C++0x
2056         https://bugs.webkit.org/show_bug.cgi?id=111559
2057
2058         Reviewed by Kenneth Rohde Christiansen.
2059
2060         * WebCore.pri:
2061
2062 2013-03-06  Julien Chaffraix  <jchaffraix@webkit.org>
2063
2064         Remove the (dead) code for handling shorthands in StyleResolver / StyleBuilder
2065         https://bugs.webkit.org/show_bug.cgi?id=111505
2066
2067         Reviewed by Alexis Menard.
2068
2069         The CSS parsing code expands shorthands (with the exception of 'font') to their longhands.
2070         This means that all the code in StyleResolver / StyleBuilder to handle shorthands is basically
2071         dead and shouldn't be there. The reason for it to be is that people didn't know about shorthands
2072         expansion and thus copied existing code.
2073
2074         This change addresses both issues by removing the code and adding ASSERTs that should prevent people
2075         from adding more dead code.
2076
2077         Refactoring, covered by existing tests.
2078
2079         * css/StylePropertyShorthand.h: Added isExpandedShorthand.
2080         * css/StylePropertyShorthand.cpp:
2081         (WebCore::isExpandedShorthand):
2082         Added this function that ignores 'font' as it is the only shorthand that is no consistently expanded
2083         to account for system fonts.
2084
2085         * css/StyleBuilder.cpp:
2086         (WebCore::StyleBuilder::StyleBuilder):
2087         Removed the shorthands.
2088
2089         * css/StyleBuilder.h:
2090         (WebCore::StyleBuilder::setPropertyHandler):
2091         Added ASSERTs that people don't add shorthand handling.
2092
2093         * css/StyleResolver.cpp:
2094         (WebCore::isValidVisitedLinkProperty):
2095         Removed all the shorthands (shouldn't be reachable unless the ASSERT in applyProperty
2096         triggers).
2097
2098         (WebCore::StyleResolver::applyProperty):
2099         Removed all shorthand handling code, moved the shorthands together and added some ASSERT
2100         to ensure people don't abuse the code and re-add some of it back by mistake.
2101
2102 2013-03-05  Kent Tamura  <tkent@chromium.org>
2103
2104         Rename WebCore/editing/visible_units.* to VisibleUnits.*
2105         https://bugs.webkit.org/show_bug.cgi?id=111426
2106
2107         Reviewed by Alexey Proskuryakov.
2108
2109         No new tests. Just a refactoring.
2110
2111         * CMakeLists.txt:
2112         * GNUmakefile.list.am:
2113         * Target.pri:
2114         * WebCore.gypi:
2115         * WebCore.vcproj/WebCore.vcproj:
2116         * WebCore.vcxproj/WebCore.vcxproj:
2117         * WebCore.vcxproj/WebCore.vcxproj.filters:
2118         * WebCore.xcodeproj/project.pbxproj:
2119         * accessibility/AccessibilityNodeObject.cpp:
2120         * accessibility/AccessibilityObject.cpp:
2121         * accessibility/AccessibilityRenderObject.cpp:
2122         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2123         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
2124         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2125         * dom/Position.cpp:
2126         * dom/Range.cpp:
2127         * editing/AlternativeTextController.cpp:
2128         * editing/ApplyBlockElementCommand.cpp:
2129         * editing/ApplyStyleCommand.cpp:
2130         * editing/CompositeEditCommand.cpp:
2131         * editing/DeleteSelectionCommand.cpp:
2132         * editing/EditingAllInOne.cpp:
2133         * editing/EditingStyle.cpp:
2134         * editing/Editor.cpp:
2135         * editing/FormatBlockCommand.cpp:
2136         * editing/FrameSelection.cpp:
2137         * editing/IndentOutdentCommand.cpp:
2138         * editing/InsertLineBreakCommand.cpp:
2139         * editing/InsertListCommand.cpp:
2140         * editing/InsertParagraphSeparatorCommand.cpp:
2141         * editing/InsertTextCommand.cpp:
2142         * editing/ReplaceSelectionCommand.cpp:
2143         * editing/SurroundingText.cpp:
2144         * editing/TextCheckingHelper.cpp:
2145         * editing/TextIterator.cpp:
2146         * editing/TypingCommand.cpp:
2147         * editing/VisiblePosition.cpp:
2148         * editing/VisibleSelection.cpp:
2149         * editing/VisibleUnits.cpp: Copied from Source/WebCore/editing/visible_units.cpp.
2150         * editing/VisibleUnits.h: Copied from Source/WebCore/editing/visible_units.h.
2151         * editing/htmlediting.cpp:
2152         * editing/markup.cpp:
2153         * editing/visible_units.cpp: Removed.
2154         * editing/visible_units.h: Removed.
2155         * page/Frame.cpp:
2156         * page/mac/FrameMac.mm:
2157         * platform/win/EditorWin.cpp:
2158
2159 2013-03-06  Alexis Menard  <alexis@webkit.org>
2160
2161         Do not add CSSPropertyBorderImage shorthand part of the property list when parsing CSS border property
2162         https://bugs.webkit.org/show_bug.cgi?id=111481
2163
2164         Reviewed by Julien Chaffraix.
2165
2166         After http://trac.webkit.org/changeset/135848 and more generally we do not 
2167         add shorthand directly into the property list used afterwards to build
2168         StylePropertySet but we rather expand the shorthand to add the
2169         longhands. CSSPropertyBorderImage is a shorthand and it should follow
2170         that rule, so when we successfully parsed CSS border property and we
2171         should reset border-image then we should reset the longhands too.
2172
2173         Test: LayoutTests/inspector/styles/styles-new-API-expected.txt which
2174         reflects the fact that we add longhands instead of the shorthand. All
2175         the other tests should not regress.
2176
2177         * css/CSSParser.cpp:
2178         (WebCore::CSSParser::parseValue):
2179
2180 2013-03-06  Luiz Agostini  <luiz.agostini@nokia.com>
2181
2182         Accelerated overflow scrolling for Coordinated Graphics.
2183         https://bugs.webkit.org/show_bug.cgi?id=110323
2184
2185         Reviewed by Noam Rosenthal.
2186
2187         A scroll offset is applied to individual layers on UI process and the
2188         web process is notified assynchronously.
2189         The new API WKCoordinatedScene may be used to scroll layers in the UI process.
2190
2191         Tests will be added on bug #111140.
2192
2193         Scrolling coordinator is used to provide a ScrollableArea to CoordinatedGraphicsLayer.
2194
2195         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp:
2196         (WebCore::ScrollingCoordinatorCoordinatedGraphics::scrollableAreaScrollLayerDidChange):
2197         (WebCore):
2198         (WebCore::ScrollingCoordinatorCoordinatedGraphics::willDestroyScrollableArea):
2199         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h:
2200         (ScrollingCoordinatorCoordinatedGraphics):
2201
2202         GraphicsLayerTextureMapper is responsible for receiving the 'did commit' messages and to pass
2203         them to its TextureMapperLayer on the appropriated time.
2204
2205         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2206         (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
2207         (WebCore::GraphicsLayerTextureMapper::didCommitScrollOffset):
2208         (WebCore):
2209         (WebCore::GraphicsLayerTextureMapper::setIsScrollable):
2210         (WebCore::GraphicsLayerTextureMapper::commitLayerChanges):
2211         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
2212         (WebCore::GraphicsLayerTextureMapper::setScrollClient):
2213         (WebCore::GraphicsLayerTextureMapper::setID):
2214         (GraphicsLayerTextureMapper):
2215         (WebCore::GraphicsLayerTextureMapper::isScrollable):
2216
2217         TextureMapperLayer is responsible for applying the requested scroll offset and for
2218         sending the commit messages to web process. It is also able to hittest layers and identify
2219         the ones that are scrollable.
2220
2221         * platform/graphics/texmap/TextureMapperLayer.cpp:
2222         (WebCore::TextureMapperLayer::hitTest):
2223         (WebCore):
2224         (WebCore::TextureMapperLayer::scrollableLayerHitTestCondition):
2225         (WebCore::TextureMapperLayer::findScrollableContentsLayerAt):
2226         (WebCore::TextureMapperLayer::mapScrollOffset):
2227         (WebCore::TextureMapperLayer::commitScrollOffset):
2228         (WebCore::TextureMapperLayer::scrollBy):
2229         (WebCore::TextureMapperLayer::didCommitScrollOffset):
2230         * platform/graphics/texmap/TextureMapperLayer.h:
2231         (TextureMapperLayer):
2232         (ScrollingClient):
2233         (WebCore::TextureMapperLayer::TextureMapperLayer):
2234         (WebCore::TextureMapperLayer::setID):
2235         (WebCore::TextureMapperLayer::id):
2236         (WebCore::TextureMapperLayer::setScrollClient):
2237         (WebCore::TextureMapperLayer::setIsScrollable):
2238         (WebCore::TextureMapperLayer::isScrollable):
2239         (WebCore::TextureMapperLayer::adjustedPosition):
2240
2241         CoordinatedGraphicsLayer receives the commit messages and updates its ScrollableArea.
2242
2243         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
2244         (WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
2245         (WebCore::CoordinatedGraphicsLayer::setScrollableArea):
2246         (WebCore):
2247         (WebCore::CoordinatedGraphicsLayer::commitScrollOffset):
2248         (WebCore::CoordinatedGraphicsLayer::resetLayerState):
2249         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
2250         (WebCore):
2251         (CoordinatedGraphicsLayer):
2252         (WebCore::CoordinatedGraphicsLayer::isScrollable):
2253
2254         CoordinatedGraphicsScene receives the commit messages from TextureMapperLayer and
2255         dispatches them on the main thread. It also has a new method that is used to find
2256         the topmost scrollable layer at a given point.
2257
2258         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2259         (WebCore::CoordinatedGraphicsScene::setLayerState):
2260         (WebCore::CoordinatedGraphicsScene::createLayer):
2261         (WebCore::CoordinatedGraphicsScene::dispatchCommitScrollOffset):
2262         (WebCore):
2263         (WebCore::CoordinatedGraphicsScene::commitScrollOffset):
2264         (WebCore::CoordinatedGraphicsScene::findScrollableContentsLayerAt):
2265         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
2266         (WebCore):
2267         (CoordinatedGraphicsSceneClient):
2268         (CoordinatedGraphicsScene):
2269
2270         New fields have been added to CoordinatedGraphicsLayerState.
2271
2272         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
2273         (CoordinatedGraphicsLayerState):
2274
2275 2013-03-06  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2276
2277         REGGRESSION (r142112): It made compositing tests fail on EFL, Qt.
2278         https://bugs.webkit.org/show_bug.cgi?id=109291
2279
2280         Reviewed by Kenneth Rohde Christiansen.
2281
2282         Report we support fixed layers.
2283
2284         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h:
2285         (WebCore::ScrollingCoordinatorCoordinatedGraphics::supportsFixedPositionLayers):
2286         (ScrollingCoordinatorCoordinatedGraphics):
2287
2288 2013-03-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2289
2290         Unreviewed, rolling out r144859.
2291         http://trac.webkit.org/changeset/144859
2292         https://bugs.webkit.org/show_bug.cgi?id=111519
2293
2294         Introduced a test that calls non-exist function on non-
2295         Chromium ports and crash on Chromium (Requested by rniwa on
2296         #webkit).
2297
2298         * html/HTMLAudioElement.h:
2299         (WebCore::HTMLAudioElement::hasPendingActivity):
2300         (HTMLAudioElement):
2301         * html/HTMLAudioElement.idl:
2302         * html/HTMLMediaElement.cpp:
2303         (WebCore::HTMLMediaElement::hasPendingActivity):
2304         * html/HTMLMediaElement.idl:
2305
2306 2013-03-06  Ilya Tikhonovsky  <loislo@chromium.org>
2307
2308         Web Inspector: Could not open Profiles panel.
2309         https://bugs.webkit.org/show_bug.cgi?id=111535
2310
2311         Reviewed by Alexander Pavlov.
2312
2313         * inspector/front-end/CPUProfileView.js:
2314         * inspector/front-end/ProfilesPanel.js:
2315
2316 2013-03-06  Tony Chang  <tony@chromium.org>
2317
2318         Crash during middle mouse click when page is removed
2319         https://bugs.webkit.org/show_bug.cgi?id=111489
2320
2321         Reviewed by Hajime Morrita.
2322
2323         Check for a null page that can happen if we remove the document from the DOM.
2324         The other methods in EventHandler also check for a null page.
2325
2326         Test: editing/pasteboard/selection-paste-crash.html
2327
2328         * page/EventHandler.cpp:
2329         (WebCore::EventHandler::handlePasteGlobalSelection):
2330
2331 2013-03-05  Eric Seidel  <eric@webkit.org>
2332
2333         Replace shouldLazyAttach bool with an enum for readability
2334         https://bugs.webkit.org/show_bug.cgi?id=111503
2335
2336         Reviewed by Dimitri Glazkov.
2337
2338         No behavioral change.
2339
2340         * bindings/cpp/WebDOMNodeCustom.cpp:
2341         (WebDOMNode::insertBefore):
2342         (WebDOMNode::replaceChild):
2343         (WebDOMNode::appendChild):
2344         * bindings/js/JSNodeCustom.cpp:
2345         (WebCore::JSNode::insertBefore):
2346         (WebCore::JSNode::replaceChild):
2347         (WebCore::JSNode::appendChild):
2348         * bindings/v8/custom/V8NodeCustom.cpp:
2349         (WebCore):
2350         (WebCore::V8Node::insertBeforeMethodCustom):
2351         (WebCore::V8Node::replaceChildMethodCustom):
2352         (WebCore::V8Node::appendChildMethodCustom):
2353         * dom/ContainerNode.cpp:
2354         (WebCore):
2355         (WebCore::ContainerNode::insertBefore):
2356         (WebCore::ContainerNode::replaceChild):
2357         (WebCore::ContainerNode::appendChild):
2358         (WebCore::updateTreeAfterInsertion):
2359         * dom/ContainerNode.h:
2360         (ContainerNode):
2361         * dom/Node.cpp:
2362         (WebCore::Node::insertBefore):
2363         (WebCore::Node::replaceChild):
2364         (WebCore::Node::appendChild):
2365         * dom/Node.h:
2366         (Node):
2367         * editing/AppendNodeCommand.cpp:
2368         (WebCore::AppendNodeCommand::doApply):
2369         * editing/InsertNodeBeforeCommand.cpp:
2370         (WebCore::InsertNodeBeforeCommand::doApply):
2371         * html/shadow/MediaControlsApple.cpp:
2372         (WebCore::MediaControlsApple::createControls):
2373         * html/shadow/MediaControlsBlackBerry.cpp:
2374         (WebCore::MediaControlsBlackBerry::createControls):
2375         * html/shadow/MediaControlsChromium.cpp:
2376         (WebCore::MediaControlsChromium::initializeControls):
2377         * html/shadow/MediaControlsChromiumAndroid.cpp:
2378         (WebCore::MediaControlsChromiumAndroid::createControls):
2379
2380 2013-03-05  Hajime Morrita  <morrita@google.com>
2381
2382         Custom Elements: CustomElementConstructor::m_name doesn't have any good use.
2383         https://bugs.webkit.org/show_bug.cgi?id=111523
2384
2385         Reviewed by Kentaro Hara.
2386
2387         This change removes CustomElementConstructor::m_name and renames
2388         m_tagName to m_name. Now generated function name is same as interface name.
2389
2390         Originally, m_name was added to specify the generated constructor
2391         name. An early version of custom element allows to give the name,
2392         but it no longer says anything about that.
2393
2394         The rename is to align the semantics of type extension mechanism
2395         of Custom Elements, where the name of a custom element isn't
2396         necessarily a tag name.
2397
2398         No new tests. Just removing old code.
2399
2400         * bindings/scripts/CodeGeneratorV8.pm:
2401         (GenerateHeader):
2402         * dom/CustomElementConstructor.cpp:
2403         (WebCore::CustomElementConstructor::create):
2404         (WebCore::CustomElementConstructor::CustomElementConstructor):
2405         (WebCore::CustomElementConstructor::createElement):
2406         * dom/CustomElementConstructor.h:
2407         (CustomElementConstructor):
2408         (WebCore::CustomElementConstructor::name):
2409         * dom/CustomElementRegistry.cpp:
2410         (WebCore::CustomElementRegistry::registerElement):
2411
2412 2013-03-05  Ilya Tikhonovsky  <loislo@chromium.org>
2413
2414         Web Inspector: Flame Chart. Provide node context info in a popover when mouse hovers over a flame chart item.
2415         https://bugs.webkit.org/show_bug.cgi?id=111442
2416
2417         Reviewed by Yury Semikhatsky.
2418
2419         FlameChart is a canvas so it is not possible to attach the popover to the items on it.
2420         It would be a bit tricky to support an offset due to complex behaviour of the popover.
2421         The simplest solution is to create a fake anchor element and move it to the right position.
2422
2423         * inspector/front-end/FlameChart.js:
2424         (WebInspector.FlameChart):
2425         (WebInspector.FlameChart.prototype._getPopoverAnchor):
2426         (WebInspector.FlameChart.prototype._showPopover):
2427         (WebInspector.FlameChart.prototype._onMouseMove):
2428         (WebInspector.FlameChart.prototype.findNodeCallback):
2429         (WebInspector.FlameChart.prototype._coordinatesToNode):
2430         (WebInspector.FlameChart.prototype.onResize):
2431         * inspector/front-end/flameChart.css:
2432         (.flame-chart .item-anchor):
2433
2434 2013-03-05  Csaba Osztrogonác  <ossy@webkit.org>
2435
2436         Unreviewed buildfix after r144787. Add missing USE(GRAPHICS_SURFACE) guards.
2437
2438         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2439         (WebCore::CoordinatedGraphicsScene::setLayerState):
2440         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
2441         (WebCore::CoordinatedGraphicsLayerState::CoordinatedGraphicsLayerState):
2442
2443 2013-03-05  Geoffrey Garen  <ggaren@apple.com>
2444
2445         Autoreleased cached pages slow down the PLT by 2%
2446         https://bugs.webkit.org/show_bug.cgi?id=111522
2447
2448         Reviewed by Filip Pizlo.
2449
2450         Let's stop doing that.
2451
2452         2% PLT speedup.
2453
2454         * history/PageCache.cpp:
2455         (WebCore::PageCache::remove):
2456
2457 2013-03-05  Hayato Ito  <hayato@chromium.org>
2458
2459         [Shadow] Implements event re-targeting for Touch Events.
2460         https://bugs.webkit.org/show_bug.cgi?id=107800
2461
2462         Reviewed by Dimitri Glazkov.
2463
2464         So far, Touch Events have been intentionally disabled in shadow
2465         tree since it allows users to access internal nodes in shadow tree
2466         by accessing Touch Event's information.
2467
2468         This patch re-targets all individual touch point's target in
2469         TouchList (touches, targetTouches and changedTouches) owned by a Touch Event
2470         before the Touch Event is dispatched so that we won't break an
2471         upper boundary of shadow DOM.
2472
2473         Touch Events re-targeting is similar to that of Mouse Events
2474         re-targeting. The difference is that a Touch Event can have more
2475         than one related target because of multiple touches. We must
2476         re-target all individual touch points which can be referred from
2477         the Touch Event.
2478
2479         Now, Touch Events can be fired in shadow tree. I've removed the
2480         existing limitation.
2481
2482         Test: fast/dom/shadow/touch-event-retargeting.html
2483
2484         * dom/EventContext.cpp:
2485         (WebCore::EventContext::isTouchEventContext):
2486         (WebCore):
2487         (WebCore::TouchEventContext::TouchEventContext):
2488         (WebCore::TouchEventContext::~TouchEventContext):
2489         (WebCore::TouchEventContext::handleLocalEvents):
2490         (WebCore::TouchEventContext::isTouchEventContext):
2491         (WebCore::TouchEventContext::checkReachability):  Used for assertion of reachability for each Touch point.
2492         * dom/EventContext.h:
2493         (WebCore):
2494         (EventContext):
2495         (TouchEventContext): Introduced to hold necessary information for re-targeting Touch event.
2496         (WebCore::TouchEventContext::touches):
2497         (WebCore::TouchEventContext::targetTouches):
2498         (WebCore::TouchEventContext::changedTouches):
2499         (WebCore::EventContext::isReachable):
2500         * dom/EventRetargeter.cpp:
2501         (WebCore::EventRetargeter::calculateEventPath):
2502         (WebCore::EventRetargeter::adjustForTouchEvent):
2503         (WebCore):
2504         (WebCore::EventRetargeter::adjustTouchList):
2505         (WebCore::EventRetargeter::adjustForRelatedTarget):
2506         (WebCore::EventRetargeter::calculateAdjustedNodes): Updated so that this can be used for Touch point re-targeting.
2507         (WebCore::EventRetargeter::buildRelatedNodeMap):
2508         * dom/EventRetargeter.h:
2509         (WebCore):
2510         (EventRetargeter):
2511         * dom/Node.cpp:
2512         (WebCore::Node::dispatchEvent):
2513         (WebCore):
2514         (WebCore::Node::dispatchTouchEvent):
2515         * dom/Node.h:
2516         (WebCore):
2517         (Node):
2518         * dom/Touch.cpp:
2519         (WebCore::Touch::Touch):
2520         (WebCore):
2521         (WebCore::Touch::cloneWithNewTarget):
2522         * dom/Touch.h:
2523         (Touch):
2524         * dom/TouchEvent.cpp:
2525         (WebCore::TouchEventDispatchMediator::create):
2526         (WebCore):
2527         (WebCore::TouchEventDispatchMediator::TouchEventDispatchMediator):
2528         (WebCore::TouchEventDispatchMediator::event):
2529         (WebCore::TouchEventDispatchMediator::dispatchEvent):
2530         * dom/TouchEvent.h:
2531         (TouchEvent):
2532         (WebCore::TouchEvent::setTouches):
2533         (WebCore::TouchEvent::setTargetTouches):
2534         (WebCore::TouchEvent::setChangedTouches):
2535         (TouchEventDispatchMediator):
2536         (WebCore):
2537         (WebCore::toTouchEvent):
2538         * dom/TouchList.cpp:
2539         (WebCore::TouchList::item):
2540         (WebCore):
2541         * dom/TouchList.h:
2542         (TouchList):
2543         * page/EventHandler.cpp:
2544         (WebCore::EventHandler::hitTestResultInFrame): Removed the limitation. Adjusting is no longer done here.
2545         (WebCore::EventHandler::handleTouchEvent):
2546
2547 2013-03-05  Hajime Morrita  <morrita@google.com>
2548
2549         [Custom Elements][V8] Custom Element doesn't need its own WrapperTypeInfo
2550         https://bugs.webkit.org/show_bug.cgi?id=111411
2551
2552         Reviewed by Kentaro Hara.
2553
2554         No new tests. No observable change yet.
2555
2556         This is a preparation for Bug 110436, where WebKit is going to
2557         allow any HTML element to be a superclass of custom elements.
2558
2559         This change eliminates WrapperTypeInfo for custom element. Instead
2560         of that, the wrapper of a custom element picks WrapperTypeInfo
2561         from most descendant built-in HTML element. For example, think about
2562         following hierarchy:
2563
2564         - ... <- HTMLElement <- HTMLDivElememnt <- ExistingCustomElement <- NewCustomElement
2565
2566         In this case, both ExistingCustomElement and NewCustomElement has
2567         HTMLDivElememnt's type info. This is because HTMLDivElememnt is
2568         the most descendant (or "the nearest") built-in HTML
2569         element. (HTMLElement isn't the most descendant.
2570         ExistingCustomElement isn't a built-in.)
2571
2572         Using such WrapperTypeInfos, created custom element wrappers can
2573         get appropriate set of method and properties regardless of its
2574         super-elements.
2575
2576         This change tells the prototype object of each built-in object
2577         which WrapperTypeInfo the native backing wants:
2578         HTMLDivElememnt.prototype knows V8HTMLDivElement::info for
2579         example. The pointer to the type info is stored into an internal
2580         field. On wrapper construction, createWrapper() walks up the
2581         prototype chain and pick the first one.
2582
2583         * bindings/v8/V8DOMConfiguration.cpp:
2584         (WebCore::V8DOMConfiguration::configureTemplate):
2585         * bindings/v8/V8HTMLCustomElement.cpp:
2586         (WebCore::findWrapperTypeOf):
2587         (WebCore::V8HTMLCustomElement::createWrapper):
2588         * bindings/v8/V8HTMLCustomElement.h:
2589         * bindings/v8/V8PerContextData.cpp:
2590         (WebCore::V8PerContextData::constructorForTypeSlowCase):
2591         * bindings/v8/WrapperTypeInfo.h:
2592         (WebCore):
2593
2594 2013-03-05  Aaron Colwell  <acolwell@chromium.org>
2595
2596         Heap-use-after-free in WebCore::HTMLMediaElement::~HTMLMediaElement
2597         https://bugs.webkit.org/show_bug.cgi?id=110623
2598
2599         Reviewed by Eric Seidel.
2600
2601         Test: http/tests/misc/delete-frame-during-readystatechange-with-gc-after-video-removal.html
2602
2603         * html/HTMLAudioElement.h:
2604         (HTMLAudioElement):
2605         * html/HTMLAudioElement.idl:
2606         * html/HTMLMediaElement.cpp:
2607         (WebCore::HTMLMediaElement::hasPendingActivity):
2608         * html/HTMLMediaElement.idl:
2609
2610 2013-03-05  Chris Fleizach  <cfleizach@apple.com>
2611  
2612         AX: Support aria-posinset/setsize
2613         https://bugs.webkit.org/show_bug.cgi?id=109725
2614
2615         Reviewed by Tim Horton.
2616
2617         Expose aria-setsize and aria-posinset through accessibility.
2618         Right now only the Mac platform exposes them.
2619
2620         Test: platform/mac/accessibility/aria-setsize-posinset.html
2621
2622         * accessibility/AccessibilityObject.cpp:
2623         (WebCore::AccessibilityObject::supportsARIASetSize):
2624         (WebCore):
2625         (WebCore::AccessibilityObject::supportsARIAPosInset):
2626         (WebCore::AccessibilityObject::ariaSetSize):
2627         (WebCore::AccessibilityObject::ariaPosInset):
2628         * accessibility/AccessibilityObject.h:
2629         (AccessibilityObject):
2630         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
2631         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
2632         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
2633         * html/HTMLAttributeNames.in:
2634
2635
2636 2013-03-05  Peter Nelson  <peter@peterdn.com>
2637
2638         [WinCairo] Support for cookies is incomplete
2639         https://bugs.webkit.org/show_bug.cgi?id=110147
2640         
2641         Expired and HttpOnly cookies no longer accessible from JavaScript.
2642         Cookies set in JavaScript now have correct domain/path.
2643
2644         Reviewed by Brent Fulgham.
2645
2646         Test: http/tests/cookies/http-get-cookie-set-in-js.html
2647
2648         * platform/network/curl/CookieJarCurl.cpp:
2649         (WebCore):
2650         (WebCore::addMatchingCurlCookie):
2651         (WebCore::getNetscapeCookieFormat):
2652         (WebCore::setCookiesFromDOM):
2653         (WebCore::cookieRequestHeaderFieldValue):
2654
2655 2013-03-05  Alec Flett  <alecflett@chromium.org>
2656
2657         Fix mac clang build with long long
2658         https://bugs.webkit.org/show_bug.cgi?id=111495
2659
2660         Unreviewed fix for mac build.
2661
2662         * Modules/indexeddb/IDBBackingStore.cpp:
2663         (WebCore::IDBBackingStore::IDBBackingStore):
2664
2665 2013-03-05  Alec Flett  <alecflett@chromium.org>
2666
2667         Fix mac clang build with long long
2668         https://bugs.webkit.org/show_bug.cgi?id=111495
2669
2670         Unreviewed fix for mac build.
2671
2672         * Modules/indexeddb/IDBBackingStore.cpp:
2673         (WebCore::IDBBackingStore::IDBBackingStore):
2674
2675 2013-03-05  Aaron Colwell  <acolwell@chromium.org>
2676
2677         Add V8Document.h include when the V8 code generator creates a toV8(Document*) call.
2678         https://bugs.webkit.org/show_bug.cgi?id=111486
2679
2680         Reviewed by Adam Barth.
2681
2682         No new tests. This doesn't change user visible behavior.
2683
2684         * bindings/scripts/CodeGeneratorV8.pm:
2685         (GenerateNamedConstructor):
2686         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2687
2688 2013-03-05  Shawn Singh  <shawnsingh@chromium.org>
2689
2690         Fix default background of a dragged image.
2691         https://bugs.webkit.org/show_bug.cgi?id=110512
2692
2693         Reviewed by Tony Chang.
2694
2695         Transparent background color (particularly visible in the padding
2696         of an element) was not being respected. The solution is to
2697         initially fill the drag image with transparent instead of white,
2698         so that any color background works correctly. This patch does not
2699         affect Apple Mac or Win platforms, given that this part of the
2700         code is #if guarded from those platforms.
2701
2702         Manual test added:
2703           ManualTests/drag-background-with-padding.html
2704
2705         Infrastructure for retrieving the drag image for pixel testing
2706         does not yet exist.
2707
2708         * page/Frame.cpp:
2709         (WebCore::Frame::nodeImage):
2710
2711 2013-03-05  Emil A Eklund  <eae@chromium.org>
2712
2713         ASSERTION FAILED: i < size(), UNKNOWN in WebCore::RenderTableSection::layout
2714         https://bugs.webkit.org/show_bug.cgi?id=108838
2715
2716         Reviewed by Levi Weintraub.
2717         
2718         Ensure that RenderTable::recalcSections is called when moving a
2719         TableSection by calling setNeedsSectionRecalc in addChild for
2720         TableSections.
2721
2722         Test: fullscreen/full-screen-table-section.html
2723
2724         * rendering/RenderTable.cpp:
2725         (WebCore::RenderTable::addChild):
2726
2727 2013-03-05  Kenneth Russell  <kbr@google.com>
2728
2729         Upgrade ANGLE to r1987
2730         https://bugs.webkit.org/show_bug.cgi?id=111381
2731
2732         Reviewed by Dean Jackson.
2733
2734         Covered by existing tests. Ran WebGL conformance tests in Safari
2735         to ensure correct operation of patch.
2736
2737         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
2738         (WebCore::GraphicsContext3D::GraphicsContext3D):
2739         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
2740         (WebCore::GraphicsContext3D::GraphicsContext3D):
2741         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
2742         (WebCore::GraphicsContext3D::GraphicsContext3D):
2743         * platform/graphics/mac/GraphicsContext3DMac.mm:
2744         (WebCore::GraphicsContext3D::GraphicsContext3D):
2745         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2746         (WebCore::GraphicsContext3DPrivate::initializeANGLE):
2747             Changed all ports to query for highp support in fragment
2748             shaders and conditionally enable it in ANGLE shader translator.
2749
2750 2013-03-05  Alec Flett  <alecflett@chromium.org>
2751
2752         IndexedDB: Add IDBBackingStoreTest
2753         https://bugs.webkit.org/show_bug.cgi?id=111233
2754
2755         Reviewed by Adam Barth.
2756
2757         These are tweaks to make IDBBackingStore more easily testable.
2758
2759         * Modules/indexeddb/IDBBackingStore.cpp:
2760         (WebCore::IDBBackingStore::IDBBackingStore): Allow use without a backing store.
2761
2762 2013-03-04  James Robinson  <jamesr@chromium.org>
2763
2764         [chromium] Move check for threaded compositing from WebCompositorSupport to Platform
2765         https://bugs.webkit.org/show_bug.cgi?id=111386
2766
2767         Reviewed by Adrienne Walker.
2768
2769         This moves checks for whether threaded compositing is enabled from WebCompositorSupport
2770         to Platform. In the case of Canvas2DLayerBridge, the check is moved completely out of
2771         the class to make it easier for tests to specify the threaded configuration to use in the test.
2772
2773         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
2774         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
2775         * platform/graphics/chromium/Canvas2DLayerBridge.h:
2776         (WebCore::Canvas2DLayerBridge::create):
2777         (Canvas2DLayerBridge):
2778         * platform/graphics/chromium/DrawingBufferChromium.cpp:
2779         (WebCore::DrawingBuffer::DrawingBuffer):
2780         * platform/graphics/skia/ImageBufferSkia.cpp:
2781         (WebCore::createAcceleratedCanvas):
2782
2783 2013-03-05  Anders Carlsson  <andersca@apple.com>
2784
2785         Split up the storage event dispatch functions further
2786         https://bugs.webkit.org/show_bug.cgi?id=111482
2787
2788         Reviewed by Beth Dakin.
2789
2790         Add new functions for dispatching storage events to a set of frames.
2791
2792         * storage/StorageAreaImpl.cpp:
2793         (WebCore::StorageAreaImpl::dispatchStorageEvent):
2794         * storage/StorageEventDispatcher.cpp:
2795         (WebCore::StorageEventDispatcher::dispatchSessionStorageEvents):
2796         (WebCore::StorageEventDispatcher::dispatchLocalStorageEvents):
2797         (WebCore):
2798         (WebCore::StorageEventDispatcher::dispatchSessionStorageEventsToFrames):
2799         (WebCore::StorageEventDispatcher::dispatchLocalStorageEventsToFrames):
2800         * storage/StorageEventDispatcher.h:
2801         (WebCore):
2802         (StorageEventDispatcher):
2803
2804 2013-03-05  Stephen Chenney  <schenney@chromium.org>
2805
2806         Crash when ImageLoader deletes Element inside SVGImageElement
2807         https://bugs.webkit.org/show_bug.cgi?id=111085
2808
2809         Reviewed by Abhishek Arya.
2810
2811         Elements with ImageLoader objects associated with them may have their
2812         final reference held by the ImageLoader (to allow events to be sent
2813         and handled). Any call on Element that causes the ImageLoader to
2814         dispatch events might then result in the final deref of the Element
2815         itself, thus leaving all the Element's "this" pointers up the stack
2816         pointing to invalid memory.
2817
2818         This change puts the deref of the Element on a timer so that, if the
2819         deref is called via a method on Element, the call stack will unwind
2820         before the deref occurs.
2821
2822         Test: svg/custom/image-with-attr-change-after-delete-crash.html
2823
2824         * loader/ImageLoader.cpp:
2825         (WebCore::ImageLoader::ImageLoader): Initialize a timer
2826         (WebCore::ImageLoader::updatedHasPendingEvent): Put deref of the
2827           element on a oneShotTimer, with appropriate assertions and checks to
2828           ensure we only ref/deref once.
2829         (WebCore::ImageLoader::timerFired): Deref the element when the timer fires.
2830         * loader/ImageLoader.h:
2831         (ImageLoader): Define a timer for controlling deref of the element.
2832
2833 2013-03-05  Antoine Quint  <graouts@apple.com>
2834
2835         Web Inspector: identify reflection layers in LayerTreeAgent
2836         https://bugs.webkit.org/show_bug.cgi?id=111419
2837
2838         We add a new property "isReflection" to the Layer objects returned
2839         to the front-end to indicate whether the layer was created to host
2840         the reflection for an element. When this new property is true, the
2841         "nodeId" property is set to point to the reflected element's node
2842         id, since there is no node per-se directly associated with this layer.
2843         We also change the "bounds" property to return absolute page coordinates
2844         such that the front-end can use this information to highlight that
2845         region in the page since metrics would otherwise be unavailable.
2846
2847         Reviewed by Dean Jackson.
2848
2849         Test: inspector-protocol/layers/layers-reflected-content.html
2850
2851         * inspector/Inspector.json:
2852         * inspector/InspectorLayerTreeAgent.cpp:
2853         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
2854
2855 2013-03-05  peavo@outlook.com  <peavo@outlook.com>
2856
2857         [WinCairo] Compile fix after r144024.
2858         https://bugs.webkit.org/show_bug.cgi?id=111306
2859
2860         Reviewed by James Robinson.
2861
2862         * page/scrolling/ScrollingCoordinator.cpp: Added guard for USE(ACCELERATED_COMPOSITING).
2863         * page/scrolling/ScrollingCoordinator.h: Added guard for USE(ACCELERATED_COMPOSITING).
2864
2865 2013-03-05  James Weatherall  <wez@chromium.org>
2866
2867         keydown and keyup events have zero keycode for some numeric pad keys under Chromium on Linux
2868         https://bugs.webkit.org/show_bug.cgi?id=85642
2869
2870         Add missing key mappings for GDK_KP_Begin, GDK_KP_Insert, GDK_KP_Delete and GDK_ISO_Level3_Shift.
2871
2872         Reviewed by Ojan Vafai.
2873
2874         * platform/chromium/KeyCodeConversionGtk.cpp:
2875         (WebCore::windowsKeyCodeForKeyEvent):
2876
2877 2013-03-05  Alec Flett  <alecflett@chromium.org>
2878
2879         IndexedDB: Properly refactor frontend/backend code by #includes
2880         https://bugs.webkit.org/show_bug.cgi?id=110653
2881
2882         Reviewed by Dimitri Glazkov.
2883
2884         IndexedDB has a distinct backend and frontend, with well defined
2885         *Interface / *Callbacks classes distinguishing them, respectively.
2886         
2887         This makes sure that the frontend and backend do not include each
2888         other and fixes build problems that occurred as a result.
2889
2890         Specifically this moves enums out of IDBCursor and IDBTransaction
2891         into IndexedDB.h in a new WebCore::IndexedDB namespace.
2892
2893         No new tests, as this is just a refactor.
2894
2895 2013-03-05  Jeffrey Pfau  <jpfau@apple.com>
2896
2897         Clear associated cache partitions when deleting origins' cache
2898         https://bugs.webkit.org/show_bug.cgi?id=111383
2899
2900         Reviewed by Maciej Stachowiak.
2901
2902         Clear the cache partitions associated with the origin being cleared.
2903
2904         Not possible to test with current automated test tools, must be tested manually.
2905
2906         * loader/cache/MemoryCache.cpp:
2907         (WebCore::MemoryCache::removeResourcesWithOrigin):
2908
2909 2013-03-04  Ojan Vafai  <ojan@chromium.org>
2910
2911         Inline min/maxInstrinsicLogicalWidth functions
2912         https://bugs.webkit.org/show_bug.cgi?id=111399
2913
2914         Reviewed by Tony Chang.
2915
2916         Turns out these functions don't need to be public and only
2917         have one caller. This patch is in preparation for supporting
2918         intrinsic widths on tables, which will need to pass in the
2919         border and padding width as an argument.
2920
2921         * rendering/RenderBox.cpp:
2922         (WebCore::RenderBox::fillAvailableMeasure):
2923         (WebCore::RenderBox::computeIntrinsicLogicalWidthUsing):
2924         (WebCore::RenderBox::computeLogicalWidthInRegionUsing):
2925         * rendering/RenderBox.h:
2926
2927 2013-03-05  Victor Carbune  <vcarbune@chromium.org>
2928
2929         Cue line-height property shouldn't be inherited from the video element
2930         https://bugs.webkit.org/show_bug.cgi?id=111262
2931
2932         Reviewed by Eric Carlson.
2933
2934         Test: media/track/track-cue-rendering-on-resize.html
2935
2936         * css/mediaControls.css:
2937         (video::-webkit-media-text-track-container): Set the default font size
2938         and family using the "font" property to also reset the line-height property.
2939
2940 2013-03-05  Joshua Bell  <jsbell@chromium.org>
2941
2942         IndexedDB: Remove some unused binding code
2943         https://bugs.webkit.org/show_bug.cgi?id=111463
2944
2945         Reviewed by Adam Barth.
2946
2947         IDBRequest got a custom V8 getter for |request| to help diagnose an issue, but the
2948         root cause was found/fixed (http://wkbug.com/110916 and http://wkbug.com/110206) so
2949         remove it. Also, IDBKey was marked ScriptWrappable but it is now explicitly converted
2950         to a ScriptValue before it gets anywhere near the binding code, so remove that too.
2951         Finally, createIDBKeyFromValue doesn't need to be exposed from IDBBindingUtilities.
2952
2953         No new tests - just removing dead code.
2954
2955         * Modules/indexeddb/IDBKey.h: No need for ScriptWrappable.
2956         * Modules/indexeddb/IDBRequest.idl: Remove custom binding (root cause of bug found).
2957         * WebCore.gypi: Ditto.
2958         * bindings/js/IDBBindingUtilities.h: Don't expose internal createIDBKeyFromValue().
2959         * bindings/v8/IDBBindingUtilities.h: Ditto.
2960         * bindings/v8/custom/V8IDBRequestCustom.cpp: Removed.
2961
2962 2013-03-05  Sheriff Bot  <webkit.review.bot@gmail.com>
2963
2964         Unreviewed, rolling out r144798.
2965         http://trac.webkit.org/changeset/144798
2966         https://bugs.webkit.org/show_bug.cgi?id=111478
2967
2968         "broke chromium windows build" (Requested by dpranke on
2969         #webkit).
2970
2971         * GNUmakefile.list.am:
2972         * Modules/indexeddb/IDBBackingStore.cpp:
2973         (WebCore::IDBBackingStore::Cursor::continueFunction):
2974         (WebCore::objectStoreCursorOptions):
2975         (WebCore::indexCursorOptions):
2976         (WebCore::IDBBackingStore::openObjectStoreCursor):
2977         (WebCore::IDBBackingStore::openObjectStoreKeyCursor):
2978         (WebCore::IDBBackingStore::openIndexKeyCursor):
2979         (WebCore::IDBBackingStore::openIndexCursor):
2980         * Modules/indexeddb/IDBBackingStore.h:
2981         (IDBBackingStore):
2982         * Modules/indexeddb/IDBCursor.cpp:
2983         (WebCore::IDBCursor::create):
2984         (WebCore::IDBCursor::IDBCursor):
2985         (WebCore::IDBCursor::continueFunction):
2986         (WebCore::IDBCursor::stringToDirection):
2987         (WebCore::IDBCursor::directionToString):
2988         * Modules/indexeddb/IDBCursor.h:
2989         (IDBCursor):
2990         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
2991         (WebCore::IDBCursorBackendImpl::IDBCursorBackendImpl):
2992         (WebCore::IDBCursorBackendImpl::deleteFunction):
2993         (WebCore::IDBCursorBackendImpl::CursorPrefetchIterationOperation::perform):
2994         * Modules/indexeddb/IDBCursorBackendImpl.h:
2995         (WebCore::IDBCursorBackendImpl::create):
2996         (WebCore::IDBCursorBackendImpl::value):
2997         (IDBCursorBackendImpl):
2998         * Modules/indexeddb/IDBCursorBackendInterface.h:
2999         (WebCore):
3000         * Modules/indexeddb/IDBCursorWithValue.cpp:
3001         (WebCore::IDBCursorWithValue::create):
3002         (WebCore::IDBCursorWithValue::IDBCursorWithValue):
3003         * Modules/indexeddb/IDBCursorWithValue.h:
3004         (IDBCursorWithValue):
3005         * Modules/indexeddb/IDBDatabase.cpp:
3006         (WebCore::IDBDatabase::transaction):
3007         * Modules/indexeddb/IDBDatabase.h:
3008         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
3009         (WebCore::GetOperation::create):
3010         (WebCore::GetOperation::GetOperation):
3011         (GetOperation):
3012         (WebCore::OpenCursorOperation::create):
3013         (WebCore::OpenCursorOperation::OpenCursorOperation):
3014         (OpenCursorOperation):
3015         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
3016         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
3017         (WebCore::IDBDatabaseBackendImpl::createIndex):
3018         (WebCore::IDBDatabaseBackendImpl::deleteIndex):
3019         (WebCore::IDBDatabaseBackendImpl::get):
3020         (WebCore::GetOperation::perform):
3021         (WebCore::IDBDatabaseBackendImpl::put):
3022         (WebCore::PutOperation::perform):
3023         (WebCore::IDBDatabaseBackendImpl::setIndexKeys):
3024         (WebCore::IDBDatabaseBackendImpl::openCursor):
3025         (WebCore::OpenCursorOperation::perform):
3026         (WebCore::CountOperation::perform):
3027         (WebCore::IDBDatabaseBackendImpl::deleteRange):
3028         (WebCore::DeleteRangeOperation::perform):
3029         (WebCore::IDBDatabaseBackendImpl::clear):
3030         (WebCore::IDBDatabaseBackendImpl::transactionStarted):
3031         (WebCore::IDBDatabaseBackendImpl::transactionFinished):
3032         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndAbortFired):
3033         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndCompleteFired):
3034         (WebCore::IDBDatabaseBackendImpl::createTransaction):
3035         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
3036         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
3037         (IDBDatabaseBackendImpl):
3038         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
3039         * Modules/indexeddb/IDBFactory.h:
3040         * Modules/indexeddb/IDBIndex.cpp:
3041         (WebCore):
3042         (WebCore::IDBIndex::openCursor):
3043         (WebCore::IDBIndex::openKeyCursor):
3044         * Modules/indexeddb/IDBObjectStore.cpp:
3045         (WebCore):
3046         (WebCore::IDBObjectStore::openCursor):
3047         * Modules/indexeddb/IDBRequest.cpp:
3048         (WebCore::IDBRequest::IDBRequest):
3049         (WebCore::IDBRequest::setCursorDetails):
3050         (WebCore::IDBRequest::setResultCursor):
3051         (WebCore::IDBRequest::onSuccess):
3052         * Modules/indexeddb/IDBRequest.h:
3053         (IDBRequest):
3054         * Modules/indexeddb/IDBTransaction.cpp:
3055         (WebCore::IDBTransaction::create):
3056         (WebCore::IDBTransaction::IDBTransaction):
3057         (WebCore::IDBTransaction::stringToMode):
3058         (WebCore::IDBTransaction::modeToString):
3059         * Modules/indexeddb/IDBTransaction.h:
3060         (WebCore::IDBTransaction::isReadOnly):
3061         (WebCore::IDBTransaction::isVersionChange):
3062         (IDBTransaction):
3063         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
3064         (WebCore::IDBTransactionBackendImpl::create):
3065         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
3066         * Modules/indexeddb/IDBTransactionBackendImpl.h:
3067         (IDBTransactionBackendImpl):
3068         (WebCore::IDBTransactionBackendImpl::mode):
3069         * Modules/indexeddb/IDBTransactionCoordinator.cpp:
3070         (WebCore::IDBTransactionCoordinator::processStartedTransactions):
3071         (WebCore::IDBTransactionCoordinator::canRunTransaction):
3072         * Modules/indexeddb/IndexedDB.h: Removed.
3073         * Target.pri:
3074         * WebCore.gypi:
3075
3076 2013-03-05  Tommy Widenflycht  <tommyw@google.com>
3077
3078         MediaStream API: Allow local and remote descriptions to be accessed after close
3079         https://bugs.webkit.org/show_bug.cgi?id=111437
3080
3081         Reviewed by Adam Barth.
3082
3083         It's quite clear in the standard that the getters should still return the old value.
3084         Also overhauling the state setters a bit to check if the new state is different.
3085
3086         Existing tests expanded to cover patch.
3087
3088         * Modules/mediastream/RTCPeerConnection.cpp:
3089         (WebCore::RTCPeerConnection::localDescription):
3090         (WebCore::RTCPeerConnection::remoteDescription):
3091         (WebCore::RTCPeerConnection::changeSignalingState):
3092         (WebCore::RTCPeerConnection::changeIceGatheringState):
3093         (WebCore::RTCPeerConnection::changeIceConnectionState):
3094
3095 2013-03-05  Charlie Reis  <creis@chromium.org>
3096
3097         Add FrameLoaderClient::didAccessInitialDocument
3098         https://bugs.webkit.org/show_bug.cgi?id=107963
3099
3100         Notifies the FrameLoaderClient if another page accesses the
3101         initial empty document of a main frame.  In this case, it is
3102         no longer safe to display the provisional URL.
3103
3104         Only takes effect for PLATFORM(CHROMIUM), since no other platforms
3105         listen to the notification.
3106
3107         Reviewed by Adam Barth.
3108
3109         * bindings/v8/V8DOMWindowShell.cpp:
3110         (WebCore::V8DOMWindowShell::setSecurityToken):
3111             Use default token for initial document.
3112         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3113             Notify loader if initial document is accessed.
3114         (WebCore::V8DOMWindow::namedSecurityCheck):
3115         (WebCore::V8DOMWindow::indexedSecurityCheck):
3116         * loader/FrameLoader.cpp:
3117         (WebCore::FrameLoader::FrameLoader):
3118         (WebCore::FrameLoader::didAccessInitialDocument):
3119         (WebCore):
3120         * loader/FrameLoader.h:
3121         (FrameLoader):
3122         * loader/FrameLoaderClient.h:
3123         (FrameLoaderClient):
3124         (WebCore::FrameLoaderClient::didAccessInitialDocument):
3125
3126 2013-03-05  Otto Derek Cheung  <otcheung@rim.com>
3127
3128         [BlackBerry] Fix assertion in CookieManager::getBackingStoreCookies
3129         https://bugs.webkit.org/show_bug.cgi?id=111468
3130
3131         Reviewed by Rob Buis.
3132         Internally reviewed by Konrad Piascik.
3133
3134         The assert in getBackingStoreCookies could be giving out false positives now
3135         that we have our fixes for cookie loading in PR 286189. The cookie store could
3136         be half loaded if the first cookie get/set call happens before the db is fully loaded.
3137         A full webkit sync call to reload the database will cause the assert to be hit.
3138
3139         Safer to flush everything out and try again.
3140
3141         * platform/blackberry/CookieManager.cpp:
3142         (WebCore::CookieManager::getBackingStoreCookies):
3143
3144 2013-03-05  Tony Gentilcore  <tonyg@chromium.org>
3145
3146         CompactHTMLToken does not need an XSSInfo pointer
3147         https://bugs.webkit.org/show_bug.cgi?id=111423
3148
3149         Reviewed by Eric Seidel.
3150
3151         The CompactHTMLToken should remain as small as possible because it is copied. This shrinks the size by one pointer
3152         by moving a relatively uncommon attribute out to its own Vector.
3153
3154         No new tests because no new functionality.
3155
3156         * html/parser/BackgroundHTMLParser.cpp:
3157         (WebCore::checkThatXSSInfosAreSafeToSendToAnotherThread):
3158         (WebCore):
3159         (WebCore::BackgroundHTMLParser::pumpTokenizer):
3160         (WebCore::BackgroundHTMLParser::sendTokensToMainThread):
3161         * html/parser/BackgroundHTMLParser.h:
3162         (BackgroundHTMLParser):
3163         * html/parser/CompactHTMLToken.cpp:
3164         (SameSizeAsCompactHTMLToken):
3165         (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread):
3166         * html/parser/CompactHTMLToken.h:
3167         (WebCore):
3168         (CompactHTMLToken):
3169         * html/parser/HTMLDocumentParser.cpp:
3170         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
3171         * html/parser/HTMLDocumentParser.h:
3172         (ParsedChunk):
3173         * html/parser/XSSAuditorDelegate.h:
3174         (XSSInfo):
3175         (WebCore):
3176
3177 2013-03-05  Anders Carlsson  <andersca@apple.com>
3178
3179         Split StorageEventDispatcher::dispatch into two functions
3180         https://bugs.webkit.org/show_bug.cgi?id=111464
3181
3182         Reviewed by Beth Dakin.
3183
3184         Split StorageEventDispatcher::dispatch into dispatchSessionStorageEvent and
3185         dispatchLocalStorageEvent and make StorageAreaImpl::dispatchStorageEvent call
3186         the right function based on the storage area type.
3187
3188         * storage/StorageAreaImpl.cpp:
3189         (WebCore::StorageAreaImpl::dispatchStorageEvent):
3190         * storage/StorageEventDispatcher.cpp:
3191         (WebCore::StorageEventDispatcher::dispatchSessionStorageEvent):
3192         (WebCore):
3193         (WebCore::StorageEventDispatcher::dispatchLocalStorageEvent):
3194         * storage/StorageEventDispatcher.h:
3195         (StorageEventDispatcher):
3196
3197 2013-03-05  Brent Fulgham  <bfulgham@webkit.org>
3198
3199         [WinCairo] Unreviewed build fix after r144024.
3200
3201         * page/scrolling/ScrollingCoordinator.cpp:
3202         (WebCore::ScrollingCoordinator::scrollLayerForScrollableArea): Handle
3203         case of not using Accelerated Compositing
3204         (WebCore::ScrollingCoordinator::horizontalScrollbarLayerForScrollableArea):
3205         (WebCore::ScrollingCoordinator::verticalScrollbarLayerForScrollableArea): Ditto.
3206
3207 2013-03-05  Alec Flett  <alecflett@chromium.org>
3208
3209         IndexedDB: Properly refactor frontend/backend code by #includes
3210         https://bugs.webkit.org/show_bug.cgi?id=110653
3211
3212         Reviewed by Dimitri Glazkov.
3213
3214         IndexedDB has a distinct backend and frontend, with well defined
3215         *Interface / *Callbacks classes distinguishing them, respectively.
3216         
3217         This makes sure that the frontend and backend do not include each
3218         other and fixes build problems that occurred as a result.
3219
3220         Specifically this moves enums out of IDBCursor and IDBTransaction
3221         into IndexedDB.h in a new WebCore::IndexedDB namespace.
3222
3223         No new tests, as this is just a refactor.
3224
3225 2013-03-05  James Robinson  <jamesr@chromium.org>
3226
3227         ContainerNode::setActive should not sleep for 100ms on platforms that do not implement synchronous repaint(true) semantics
3228         https://bugs.webkit.org/show_bug.cgi?id=87054
3229
3230         Reviewed by Darin Adler.
3231
3232         Adds a new ChromeClient function to query if the platform supports the immediate parameter
3233         to the invalidation APIs and guards the synchronous repaint logic in ContainerNode::setActive()
3234         with it.
3235
3236         * dom/ContainerNode.cpp:
3237         (WebCore::ContainerNode::setActive):
3238         * page/ChromeClient.h:
3239         (WebCore::ChromeClient::supportsImmediateInvalidation):
3240
3241 2013-03-05  Anders Carlsson  <andersca@apple.com>
3242
3243         Simplify storage event dispatch somewhat
3244         https://bugs.webkit.org/show_bug.cgi?id=111461
3245
3246         Reviewed by Beth Dakin.
3247
3248         Add a StorageAreaImpl::dispatchStorageEvent to avoid replicating the calls to
3249         StorageEventDispatcher::dispatch there times. This is in preparation for changing the
3250         interface of StorageEventDispatcher so it can be used by WebKit2.
3251
3252         * storage/StorageAreaImpl.cpp:
3253         (WebCore::StorageAreaImpl::setItem):
3254         (WebCore::StorageAreaImpl::removeItem):
3255         (WebCore::StorageAreaImpl::clear):
3256         (WebCore::StorageAreaImpl::dispatchStorageEvent):
3257
3258         * storage/StorageAreaImpl.h:
3259         Reindent.
3260
3261 2013-03-05  Tony Chang  <tony@chromium.org>
3262
3263         Fix some crashes in render sliders
3264         https://bugs.webkit.org/show_bug.cgi?id=111458
3265
3266         Reviewed by Ojan Vafai.
3267
3268         Fix some cases where we assumed the renderer is a renderBox.
3269
3270         Test: fast/forms/range/slider-inline-crash.html
3271
3272         * html/shadow/SliderThumbElement.cpp:
3273         (WebCore::RenderSliderContainer::layout): Use renderBox() which will return 0 if the renderer is not a RenderBox.
3274         (WebCore::SliderThumbElement::setPositionFromPoint): Bail out early if renderBox() is 0.
3275
3276 2013-03-04  Andrew Scherkus  <scherkus@chromium.org>
3277
3278         REGRESSION(r142191): Fix closed caption buttons for ports still using the painting path.
3279         https://bugs.webkit.org/show_bug.cgi?id=111109
3280
3281         Reviewed by Eric Carlson.
3282
3283         Covered by following tests:
3284         media/track/track-cue-rendering-horizontal.html
3285         media/track/track-cue-rendering-vertical.html
3286
3287         * rendering/RenderTheme.cpp:
3288         (WebCore::RenderTheme::paint):
3289         * rendering/RenderTheme.h:
3290         (WebCore::RenderTheme::paintMediaToggleClosedCaptionsButton):
3291
3292 2013-03-05  Gwang Yoon Hwang  <ryumiel@company100.net>
3293
3294         Coordinated Graphics: CoordinatedGraphicsLayer makes CoordinatedGraphicsScene perform via CoordinatedGraphicsState.
3295         https://bugs.webkit.org/show_bug.cgi?id=108294
3296
3297         Reviewed by Anders Carlsson.
3298
3299         CoordinatedLayerTreeHostProxy has too many IPC messages (e.g. SyncCanvas and
3300         CreateTile), and there is a long function chain from CoordinatedGraphicsLayer to
3301         CoordinatedGraphicsScene (4 classes).
3302         If we want to add a new message, we need to add similar functions into 4 classes.
3303
3304         Now CoordinatedLayerTreeHost has only one IPC message for CoordinatedGraphicsLayer:
3305         CommitCoordinatedGraphicsState.
3306         CoordinatedGraphicsLayer makes CoordinatedGraphicsScene run as follows:
3307         1. CoordinatedGraphicsLayer makes a CoordinatedGraphicsLayerState.
3308         2. CoordinatedLayerTreeHost stores all LayerStates.
3309         3. CoordinatedLayerTreeHost sends GraphicsState includes LayerStates to CoordinatedLayerTreeHostProxy
3310         at the moment of flushing via CommitCoordinatedGraphicsState message.
3311         4. CoordinatedGraphicsScene applies all state changes to layers.
3312
3313         There is one big behavior change. All states changes (e.g.
3314         UpdateTiles, SetLayerChildren, and etc..) are performed at the same time, when
3315         CoordinatedGraphicsScene::commitCoordinatedGraphicsState is called.
3316
3317         This patch is based on Dongsung Huang, and Noam's work in
3318         https://bugs.webkit.org/show_bug.cgi?id=108294
3319
3320         No new tests, covered by existing tests.
3321
3322         * Target.pri:
3323         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
3324         (WebCore::CoordinatedGraphicsLayer::setPosition):
3325         (WebCore::CoordinatedGraphicsLayer::setAnchorPoint):
3326         (WebCore::CoordinatedGraphicsLayer::setSize):
3327         (WebCore::CoordinatedGraphicsLayer::setTransform):
3328         (WebCore::CoordinatedGraphicsLayer::setChildrenTransform):
3329         (WebCore::CoordinatedGraphicsLayer::setPreserves3D):
3330         (WebCore::CoordinatedGraphicsLayer::setMasksToBounds):
3331         (WebCore::CoordinatedGraphicsLayer::setDrawsContent):
3332         (WebCore::CoordinatedGraphicsLayer::setContentsVisible):
3333         (WebCore::CoordinatedGraphicsLayer::setContentsOpaque):
3334         (WebCore::CoordinatedGraphicsLayer::setBackfaceVisibility):
3335         (WebCore::CoordinatedGraphicsLayer::setOpacity):
3336         (WebCore::CoordinatedGraphicsLayer::setContentsRect):
3337         (WebCore::CoordinatedGraphicsLayer::setFilters):
3338         (WebCore::CoordinatedGraphicsLayer::setContentsToSolidColor):
3339         (WebCore::CoordinatedGraphicsLayer::setShowDebugBorder):
3340         (WebCore::CoordinatedGraphicsLayer::setShowRepaintCounter):
3341         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
3342         (WebCore::CoordinatedGraphicsLayer::setReplicatedByLayer):
3343         (WebCore::CoordinatedGraphicsLayer::setFixedToViewport):
3344         (WebCore::CoordinatedGraphicsLayer::syncChildren):
3345         (WebCore::CoordinatedGraphicsLayer::syncFilters):
3346         (WebCore::CoordinatedGraphicsLayer::syncImageBacking):
3347         (WebCore::CoordinatedGraphicsLayer::syncLayerState):
3348         (WebCore::CoordinatedGraphicsLayer::setDebugBorder):
3349         (WebCore::CoordinatedGraphicsLayer::syncAnimations):
3350         (WebCore::CoordinatedGraphicsLayer::syncCanvas):
3351         (WebCore::CoordinatedGraphicsLayer::destroyCanvasIfNeeded):
3352         (WebCore::CoordinatedGraphicsLayer::createCanvasIfNeeded):
3353         (WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):
3354         (WebCore::CoordinatedGraphicsLayer::resetLayerState):
3355         (WebCore):
3356         (WebCore::CoordinatedGraphicsLayer::releaseImageBackingIfNeeded):
3357         (WebCore::CoordinatedGraphicsLayer::setRootLayer):
3358         (WebCore::CoordinatedGraphicsLayer::tiledBackingStorePaintEnd):
3359         (WebCore::CoordinatedGraphicsLayer::createTile):
3360         (WebCore::CoordinatedGraphicsLayer::updateTile):
3361         (WebCore::CoordinatedGraphicsLayer::removeTile):
3362         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
3363         (CoordinatedGraphicsLayerClient):
3364         (CoordinatedGraphicsLayer):
3365         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
3366         (WebCore::CoordinatedGraphicsScene::createCanvasIfNeeded):
3367         (WebCore::CoordinatedGraphicsScene::syncCanvasIfNeeded):
3368         (WebCore::CoordinatedGraphicsScene::destroyCanvasIfNeeded):
3369         (WebCore::CoordinatedGraphicsScene::setLayerRepaintCountIfNeeded):
3370         (WebCore::CoordinatedGraphicsScene::setLayerChildrenIfNeeded):
3371         (WebCore::CoordinatedGraphicsScene::setLayerFiltersIfNeeded):
3372         (WebCore::CoordinatedGraphicsScene::setLayerState):
3373         (WebCore::CoordinatedGraphicsScene::deleteLayer):
3374         (WebCore::CoordinatedGraphicsScene::createTilesIfNeeded):
3375         (WebCore::CoordinatedGraphicsScene::removeTilesIfNeeded):
3376         (WebCore::CoordinatedGraphicsScene::updateTilesIfNeeded):
3377         (WebCore::CoordinatedGraphicsScene::assignImageBackingToLayer):
3378         (WebCore::CoordinatedGraphicsScene::commitSceneState):
3379         (WebCore::CoordinatedGraphicsScene::setLayerAnimationsIfNeeded):
3380         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
3381         (WebCore):
3382         (CoordinatedGraphicsScene):
3383         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h: Added.
3384         (WebCore):
3385         (TileUpdateInfo):
3386         (TileCreationInfo):
3387         (WebCore::CoordinatedGraphicsLayerState::CoordinatedGraphicsLayerState):
3388         (CoordinatedGraphicsLayerState):
3389         (CoordinatedGraphicsState):
3390         * platform/graphics/texmap/coordinated/CoordinatedImageBacking.h:
3391         * platform/graphics/texmap/coordinated/CoordinatedLayerInfo.h: Removed.
3392         * platform/graphics/texmap/coordinated/SurfaceUpdateInfo.h:
3393
3394 2013-03-05  Roger Fong  <roger_fong@apple.com>
3395
3396         Unreviewed. AppleWin VS2010 build fix.
3397
3398         * WebCore.vcxproj/WebCore.vcxproj:
3399         * WebCore.vcxproj/WebCore.vcxproj.filters:
3400         * rendering/RenderingAllInOne.cpp:
3401
3402 2013-03-05  Bem Jones-Bey  <bjonesbe@adobe.com>
3403
3404         [CSS Exclusions] shape-outside on floats for polygon shapes
3405         https://bugs.webkit.org/show_bug.cgi?id=98676
3406
3407         Reviewed by David Hyatt.
3408
3409         Implement support for polygonal shape-outside on floats. The basic
3410         tack taken here is to keep using the bounding box of the shape to
3411         position the float, but to compute the offset (caused by the shape)
3412         from the bounding box for each line when creating and positioning
3413         other inline content.
3414
3415         Test: fast/exclusions/shape-outside-floats/shape-outside-floats-simple-polygon.html
3416
3417         * rendering/ExclusionShapeInfo.cpp:
3418         (WebCore):
3419         (WebCore::::computedShape): Add new template parameter.
3420         (WebCore::::logicalTopOffset): Add new template parameter.
3421         (WebCore::::computeSegmentsForLine): Move here from
3422             ExclusionShapeInsideInfo, since ExclusionShapeOutsideInfo needs it
3423             as well. Make virtual since there is slightly different behavior
3424             between each class even though the vast majority of the code is
3425             common.
3426         * rendering/ExclusionShapeInfo.h:
3427         (WebCore):
3428         (WebCore::ExclusionShapeInfo::~ExclusionShapeInfo): Since
3429             computeSegmentsForLine is virtual, the destructor must be virtual
3430             as well.
3431         (ExclusionShapeInfo): Add new data members to support
3432             computeSegmentsForLine.
3433         (WebCore::ExclusionShapeInfo::shapeLogicalRight): Fix bug, the logical
3434             right is based off of maxX, not y. (it's a logical bounding box!)
3435         (WebCore::ExclusionShapeInfo::logicalLineTop): Moved from
3436             ExclusionShapeInsideInfo for use by computeSegmentsForLine and
3437             lineOverlapsShapeBounds.
3438         (WebCore::ExclusionShapeInfo::logicalLineBottom): Moved from
3439             ExclusionShapeInsideInfo for use by computeSegmentsForLine and
3440             lineOverlapsShapeBounds.
3441         (WebCore::ExclusionShapeInfo::lineOverlapsShapeBounds): Moved from
3442             ExclusionShapeInsideInfo for use by computeSegmentsForLine.
3443         * rendering/ExclusionShapeInsideInfo.cpp: Moved common code from
3444             computeSegmentsForLine into ExclusionShapeInfo.
3445         * rendering/ExclusionShapeInsideInfo.h:
3446         (WebCore): Moved some methods to ExclusionShapeInfo.
3447         (ExclusionShapeInsideInfo): Update for new template parameter.
3448         (WebCore::ExclusionShapeInsideInfo::compyteSegmentsForLine): Override
3449             superclass method to clear the segment ranges. Segement ranges
3450             aren't used by shape outside, and have some complex dependencies
3451             that make it very hard to try and move up into ExclusionShapeInfo.
3452         (WebCore::ExclusionShapeInsideInfo::ExclusionShapeInsideInfo): Update
3453             for new template parameter.
3454         * rendering/ExclusionShapeOutsideInfo.cpp:
3455         (WebCore::ExclusionShapeOutsideInfo::isEnabledFor): Add polygons as a
3456             supported shape.
3457         (WebCore::ExclusionShapeOutsideInfo::computeSegmentsForLine): Override
3458             superclass method to not recompute if it isn't needed (this isn't
3459             straightfoward for shape inside, which is why it isn't common),
3460             and to save the left and right offsets caused by the shape
3461             outside, since that's all that is needed to properly do layout in
3462             the case of floats.
3463         * rendering/ExclusionShapeOutsideInfo.h:
3464         (WebCore::ExclusionShapeOutsideInfo::shapeLogicalOffset): Reformat to
3465             be on a sin