0f578849dc2c72307e4d4668fec9dd9934a9cf04
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-08-03  Yury Semikhatsky  <yurys@chromium.org>
2
3         Unreviewed. Fixed WinCE compilation after r124589.
4
5         * css/PropertySetCSSStyleDeclaration.cpp:
6         (WebCore::StyleRuleCSSStyleDeclaration::reportMemoryUsage):
7         (WebCore::InlineCSSStyleDeclaration::reportMemoryUsage):
8
9 2012-08-03  Keishi Hattori  <keishi@webkit.org>
10
11         Add keyboard support for color suggestion popup
12         https://bugs.webkit.org/show_bug.cgi?id=93069
13
14         Reviewed by Kent Tamura.
15
16         This adds support for keyboard inside the color suggestion popup.
17         Tab or arrow keys to move around. Return or space to select the color.
18         Escape closes the popup.
19
20         No new tests. Covered in platform/chromium/fast/forms/color/color-suggestion-picker-appearance.html.
21
22         * Resources/colorSuggestionPicker.css:
23         (.color-swatch):
24         (.color-swatch:focus):
25         * Resources/colorSuggestionPicker.js:
26         (ColorPicker):
27         (ColorPicker.prototype._layout):
28         (ColorPicker.prototype.selectColorAtIndex): Selects color at index.
29         (ColorPicker.prototype._handleMouseMove): Set focus to the swatch under the mouse cursor.
30         (ColorPicker.prototype._handleKeyDown): Move focused element on arrow keys.
31         (ColorPicker.prototype._handleMouseDown): Prevents blur on click.
32
33 2012-08-03  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
34
35         Add missing include to build on Mac OS 10.8
36
37         Reviewed by Ossy.
38
39         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
40
41 2012-08-03  Adam Barth  <abarth@webkit.org>
42
43         [V8] Re-wire "target" half of the same-origin security check through Document rather than DOMWindow
44         https://bugs.webkit.org/show_bug.cgi?id=93079
45
46         Reviewed by Eric Seidel.
47
48         Before this patch, we were traversing from Nodes to Frames to
49         DOMWindows to SecurityOrigins when determing the "target" of an
50         operation for the same-origin policy security check. Rather than
51         detouring through DOMWindow, these security checks should operate in
52         terms of ScriptExecutionContexts (aka Documents) because that's the
53         canonical place we store SecurityOrigin objects.
54
55         A future patch will re-wire the "active" part of the security check to
56         use ScriptExecutionContexts as well and we'll be able to remove the
57         extra copy of SecurityOrigin that we keep in DOMWindow.
58
59         * bindings/generic/BindingSecurity.cpp:
60         (WebCore::canAccessDocument):
61         (WebCore::BindingSecurity::canAccessFrame):
62         (WebCore::BindingSecurity::shouldAllowAccessToNode):
63         * bindings/v8/BindingState.cpp:
64         (WebCore::immediatelyReportUnsafeAccessTo):
65         * bindings/v8/BindingState.h:
66         (WebCore):
67         * bindings/v8/V8DOMWindowShell.cpp:
68         (WebCore::reportUnsafeJavaScriptAccess):
69         * bindings/v8/V8Proxy.cpp:
70         (WebCore::V8Proxy::reportUnsafeAccessTo):
71         * bindings/v8/V8Proxy.h:
72         (V8Proxy):
73
74 2012-08-03  Keishi Hattori  <keishi@webkit.org>
75
76         ColorSuggestionPicker popup's height doesn't get smaller than 100 px
77         https://bugs.webkit.org/show_bug.cgi?id=92945
78
79         Reviewed by Kent Tamura.
80
81         A window cannot be resized to be smaller than 100x100 pixels so this
82         adjust the color suggestion popup UI to look better when there are only
83         a few suggestions.
84
85         Tests: platform/chromium/fast/forms/color/color-suggestion-picker-one-row-appearance.html
86                platform/chromium/fast/forms/color/color-suggestion-picker-two-row-appearance.html
87
88         * Resources/colorSuggestionPicker.css:
89         (.color-swatch-container): Vertically center the swatches.
90
91 2012-08-03  Alexander Pavlov  <apavlov@chromium.org>
92
93         Web Inspector: Remove InspectorCSSAgent from InstrumentingAgents on clearFrontend()
94         https://bugs.webkit.org/show_bug.cgi?id=93082
95
96         Reviewed by Yury Semikhatsky.
97
98         * inspector/InspectorCSSAgent.cpp:
99         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
100         (WebCore::InspectorCSSAgent::~InspectorCSSAgent):
101         (WebCore::InspectorCSSAgent::setFrontend):
102         (WebCore::InspectorCSSAgent::clearFrontend):
103
104 2012-08-03  Eugene Klyuchnikov  <eustas.big@gmail.com>
105
106         Web Inspector: Profiles: extract save to file / load from code
107         https://bugs.webkit.org/show_bug.cgi?id=92348
108
109         Reviewed by Yury Semikhatsky.
110
111         Motivation: extract reusable code for timeline load/save.
112         FileUtils.js will contain common code. Not all code moved to FileUtils
113         to make review easier. This code will be moved in next patch.
114
115         Core abstractions: OutputStream and OutputStreamDelegate.
116
117         OutputStream is interface that is used to transfer entity divded
118         to chunks. Transfer process is explicitly initialized (startTransfer)
119         and finalized (finishTrnsfer).
120
121         OutputStreamDelegate is interface to receive notifications about
122         transfer process: onTransferStarted, onChunkTransferred, onTransferFinished.
123
124         ChunkedFileReader: utility class that loads file by chunks of specified
125         size and notifies given delegate. OutputStream is supplied as a
126         parameter of method "start".
127
128         ChunkedFileWriter: implementation of OutputStream that saves data
129         to file specified by file name and notifies given delegate.
130
131         * WebCore.gypi: Added 'FileUtils.js'.
132         * WebCore.vcproj/WebCore.vcproj: Added 'FileUtils.js'.
133         * inspector/compile-front-end.py: Added 'FileUtils.js'.
134         * inspector/front-end/FileUtils.js: Added.
135         (WebInspector.OutputStreamDelegate): Added.
136         (WebInspector.ChunkedFileReader): Added.
137         (WebInspector.createFileSelectorElement): Added utility method to construct
138         hidden input element to select file.
139         * inspector/front-end/HeapSnapshotLoader.js: Adopted new API.
140         * inspector/front-end/HeapSnapshotProxy.js: Adopted new API.
141         * inspector/front-end/HeapSnapshotView.js: Adopted new API.
142         (WebInspector.HeapSnapshotLoadFromFileDelegate):
143         Extracted from existing code.
144         (WebInspector.ChunkedFileWriter): Renamed and refactored.
145         (WebInspector.HeapSnapshotSaveToFileDelegate):
146         Extracted from existing code.
147         * inspector/front-end/ProfilesPanel.js: Adopted new API.
148
149 2012-08-03  Alexander Pavlov  <apavlov@chromium.org>
150
151         Web Inspector: Incorrect blob url href when inspecting
152         https://bugs.webkit.org/show_bug.cgi?id=93076
153
154         Reviewed by Vsevolod Vlasov.
155
156         Special-cased the "blob" scheme to return the original URL intact on completion.
157
158         * inspector/front-end/ResourceUtils.js:
159         (WebInspector.completeURL):
160
161 2012-08-03  Yury Semikhatsky  <yurys@chromium.org>
162
163         Web Inspector: add CSSRule memory instrumentation
164         https://bugs.webkit.org/show_bug.cgi?id=92962
165
166         Reviewed by Pavel Feldman.
167
168         Added memory footprint reporting method to CSSRule and its descendants.
169
170         * css/CSSCharsetRule.cpp:
171         (WebCore::CSSCharsetRule::reportDescendantMemoryUsage):
172         (WebCore):
173         * css/CSSCharsetRule.h:
174         (CSSCharsetRule):
175         * css/CSSComputedStyleDeclaration.cpp:
176         (WebCore::CSSComputedStyleDeclaration::reportMemoryUsage):
177         (WebCore):
178         * css/CSSComputedStyleDeclaration.h:
179         (CSSComputedStyleDeclaration):
180         * css/CSSFontFaceRule.cpp:
181         (WebCore::CSSFontFaceRule::reportDescendantMemoryUsage):
182         (WebCore):
183         * css/CSSFontFaceRule.h:
184         (CSSFontFaceRule):
185         * css/CSSImportRule.cpp:
186         (WebCore::CSSImportRule::reportDescendantMemoryUsage):
187         (WebCore):
188         * css/CSSImportRule.h:
189         (CSSImportRule):
190         * css/CSSMediaRule.cpp:
191         (WebCore::CSSMediaRule::reportDescendantMemoryUsage):
192         (WebCore):
193         * css/CSSMediaRule.h:
194         (CSSMediaRule):
195         * css/CSSPageRule.cpp:
196         (WebCore::CSSPageRule::reportDescendantMemoryUsage):
197         (WebCore):
198         * css/CSSPageRule.h:
199         (CSSPageRule):
200         * css/CSSRule.cpp:
201         (WebCore::CSSRule::reportMemoryUsage): we manually implement polymorphic
202         call here to avoid adding vtable pointer to all CSSRule objects. Descendants
203         are expected to report their memory via reportDescendantMemoryUsage. The name
204         is intentionally different from reportMemoryUsage to avoid accidential infitite
205         recursion: if the descendants overrode non-virtual CSSRule::reportMemoryUsage,
206         it would be easy to add a new descendant type to the switch in
207         CSSRule::reportMemoryUsage without providing proper override for reportMemoryUsage
208         and CSSRule::reportMemoryUsage would end up calling itself.
209         (WebCore):
210         (WebCore::CSSRule::reportBaseClassMemoryUsage): again we cannot use
211         MemoryClassInfo::visitBaseClass like we do for virtual methods because it would
212         lead to a recursive call of CSSRule::reportMemoryUsage. This is why we use
213         reportBaseClassMemoryUsage to allow descendants to report objects referenced
214         from their base class.
215         * css/CSSRule.h:
216         (WebCore):
217         (CSSRule):
218         * css/CSSRuleList.cpp:
219         (WebCore::StaticCSSRuleList::reportMemoryUsage):
220         (WebCore):
221         * css/CSSRuleList.h:
222         (WebCore):
223         (CSSRuleList):
224         (StaticCSSRuleList):
225         (LiveCSSRuleList):
226         * css/CSSStyleDeclaration.h:
227         (WebCore):
228         (CSSStyleDeclaration):
229         * css/CSSStyleRule.cpp:
230         (WebCore::CSSStyleRule::reportDescendantMemoryUsage):
231         (WebCore):
232         * css/CSSStyleRule.h:
233         (CSSStyleRule):
234         * css/CSSStyleSheet.cpp:
235         (StyleSheetCSSRuleList):
236         (WebCore::CSSStyleSheet::reportMemoryUsage):
237         * css/CSSUnknownRule.h:
238         (CSSUnknownRule):
239         (WebCore::CSSUnknownRule::reportDescendantMemoryUsage):
240         * css/PropertySetCSSStyleDeclaration.cpp:
241         (WebCore::PropertySetCSSStyleDeclaration::reportMemoryUsage):
242         (WebCore):
243         (WebCore::StyleRuleCSSStyleDeclaration::reportMemoryUsage):
244         (WebCore::InlineCSSStyleDeclaration::reportMemoryUsage):
245         * css/PropertySetCSSStyleDeclaration.h:
246         (PropertySetCSSStyleDeclaration):
247         (StyleRuleCSSStyleDeclaration):
248         (InlineCSSStyleDeclaration):
249         * css/WebKitCSSKeyframeRule.cpp:
250         (WebCore::WebKitCSSKeyframeRule::reportDescendantMemoryUsage):
251         (WebCore):
252         * css/WebKitCSSKeyframeRule.h:
253         (WebKitCSSKeyframeRule):
254         * css/WebKitCSSKeyframesRule.cpp:
255         (WebCore::WebKitCSSKeyframesRule::reportDescendantMemoryUsage):
256         (WebCore):
257         * css/WebKitCSSKeyframesRule.h:
258         (WebKitCSSKeyframesRule):
259         * css/WebKitCSSRegionRule.cpp:
260         (WebCore::WebKitCSSRegionRule::reportDescendantMemoryUsage):
261         (WebCore):
262         * css/WebKitCSSRegionRule.h:
263         (WebKitCSSRegionRule):
264
265 2012-08-03  Adam Barth  <abarth@webkit.org>
266
267         WebCore::DragController::cleanupAfterSystemDrag should null-check page
268         https://bugs.webkit.org/show_bug.cgi?id=61815
269
270         Reviewed by Eric Seidel.
271
272         * page/DragController.cpp:
273         (WebCore::DragController::dragEnteredOrUpdated):
274         (WebCore::DragController::doSystemDrag):
275
276 2012-08-03  Sergio Carlos Morales Angeles  <carloschilazo@gmail.com>
277
278         Delete text from password does nothing.
279         https://bugs.webkit.org/show_bug.cgi?id=92040
280
281         Reviewed by Ryosuke Niwa.
282
283         Use Editor::canDelete() to determine if field is editable or not.
284         Added password-delete-contents test.
285
286         Test: editing/deleting/password-delete-contents.html
287
288         * editing/EditorCommand.cpp:
289         (WebCore::enabledDelete):
290
291 2012-08-03  Jan Keromnes  <janx@linux.com>
292
293         Web Inspector: Make textModel private to textEditor
294         https://bugs.webkit.org/show_bug.cgi?id=92999
295
296         Reviewed by Pavel Feldman.
297
298         Making textModel private to the textEditor ensures that it is accessed
299         only through the textEditor, making the latter more modular.
300
301         Tests were changed accordingly.
302
303         * inspector/front-end/JavaScriptSourceFrame.js:
304         (WebInspector.JavaScriptSourceFrame.prototype.afterTextChanged):
305         (WebInspector.JavaScriptSourceFrame.prototype._restoreBreakpointsAfterEditing):
306         (WebInspector.JavaScriptSourceFrame.prototype._addBreakpointDecoration):
307         (WebInspector.JavaScriptSourceFrame.prototype._removeBreakpointDecoration):
308         (WebInspector.JavaScriptSourceFrame.prototype._lineNumberAfterEditing):
309         * inspector/front-end/SourceFrame.js:
310         (WebInspector.SourceFrame):
311         (WebInspector.SourceFrame.prototype.setContent):
312         (WebInspector.SourceFrame.prototype.replaceAllWith):
313         (WebInspector.SourceFrame.prototype._collectRegexMatches):
314         (WebInspector.SourceFrame.prototype.addMessageToSource):
315         (WebInspector.SourceFrame.prototype.removeMessageFromSource):
316         (WebInspector.TextEditorDelegateForSourceFrame.prototype.commitEditing):
317         * inspector/front-end/TextEditor.js:
318         (WebInspector.TextEditor.prototype.setText):
319         (WebInspector.TextEditor.prototype.text):
320         (WebInspector.TextEditor.prototype.range):
321         (WebInspector.TextEditor.prototype.line):
322         (WebInspector.TextEditor.prototype.get linesCount):
323         (WebInspector.TextEditor.prototype.setAttribute):
324         (WebInspector.TextEditor.prototype.getAttribute):
325         (WebInspector.TextEditor.prototype.removeAttribute):
326         * inspector/front-end/UISourceCodeFrame.js:
327         (WebInspector.UISourceCodeFrame.prototype.afterTextChanged):
328
329 2012-08-03  Adam Barth  <abarth@webkit.org>
330
331         V8Proxy::retrieve(*) leads to really obfuscated code and should be removed
332         https://bugs.webkit.org/show_bug.cgi?id=93072
333
334         Reviewed by Eric Seidel.
335
336         Once upon a time, V8Proxy::retrieve did a bunch of checks before
337         returning the V8Proxy object (such as checking whether script was
338         enabled). Over time, we've removed all of these checks in order to fix
339         various bugs. Now all it does is check whether the Frame is 0. However,
340         because the function ends up returning 0 when its argument is 0, the
341         caller sill needs to have a null check.
342
343         This patch deletes all the variations of V8Proxy::retrieve(*) and
344         inlines them into their callers. In several cases, inlining the
345         function call showed that we were testing the Frame for 0 twice, and
346         I've removed the redundant null checks. In other cases, I've
347         uncontorted the callers to make the code more readable.
348
349         * bindings/scripts/CodeGeneratorV8.pm:
350         (GenerateToV8Converters):
351         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
352         (WebCore::V8TestActiveDOMObject::wrapSlow):
353         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
354         (WebCore::V8TestNamedConstructorConstructorCallback):
355         * bindings/scripts/test/V8/V8TestNode.cpp:
356         (WebCore::V8TestNode::wrapSlow):
357         * bindings/v8/PageScriptDebugServer.cpp:
358         (WebCore::PageScriptDebugServer::addListener):
359         * bindings/v8/ScheduledAction.cpp:
360         (WebCore::ScheduledAction::execute):
361         * bindings/v8/ScriptController.h:
362         (WebCore::ScriptController::windowShell):
363         * bindings/v8/V8DOMWrapper.cpp:
364         (WebCore::V8DOMWrapper::instantiateV8Object):
365         * bindings/v8/V8EventListener.cpp:
366         (WebCore::V8EventListener::callListenerFunction):
367         * bindings/v8/V8Helpers.cpp:
368         (WebCore::toV8Proxy):
369         * bindings/v8/V8LazyEventListener.cpp:
370         (WebCore::V8LazyEventListener::callListenerFunction):
371         (WebCore::V8LazyEventListener::prepareListenerObject):
372         * bindings/v8/V8Proxy.cpp:
373         (WebCore::V8Proxy::handleOutOfMemory):
374         (WebCore::V8Proxy::retrievePerContextData):
375         (WebCore::V8Proxy::mainWorldContext):
376         (WebCore::toV8Context):
377         * bindings/v8/V8Proxy.h:
378         (V8Proxy):
379         * bindings/v8/custom/V8DOMWindowCustom.cpp:
380         (WebCore::V8DOMWindow::addEventListenerCallback):
381         (WebCore::V8DOMWindow::removeEventListenerCallback):
382         * bindings/v8/custom/V8DocumentCustom.cpp:
383         (WebCore::toV8):
384         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
385         (WebCore::V8HTMLDocument::openCallback):
386         (WebCore::toV8):
387         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
388         (WebCore::toV8):
389
390 2012-08-03  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
391
392         Add *explicit* keyword to constructors in WebCore/accessibility
393         https://bugs.webkit.org/show_bug.cgi?id=93067
394
395         Reviewed by Kentaro Hara.
396
397         As a step to add *explicit* keyword to constructors which have a parameter,
398         *explicit* keyword is added to Source/WebCore/accessibility in order to avoid
399         implicit type conversion.
400
401         No new tests. Covered by existing tests.
402
403         * accessibility/AXObjectCache.h:
404         (AXObjectCache):
405         * accessibility/AccessibilityARIAGrid.h:
406         (AccessibilityARIAGrid):
407         * accessibility/AccessibilityARIAGridCell.h:
408         (AccessibilityARIAGridCell):
409         * accessibility/AccessibilityARIAGridRow.h:
410         (AccessibilityARIAGridRow):
411         * accessibility/AccessibilityList.h:
412         (AccessibilityList):
413         * accessibility/AccessibilityListBox.h:
414         (AccessibilityListBox):
415         * accessibility/AccessibilityMediaControls.h:
416         (AccessibilityMediaControl):
417         (AccessibilityMediaTimeline):
418         (AccessibilityMediaControlsContainer):
419         (AccessibilityMediaTimeDisplay):
420         * accessibility/AccessibilityMenuList.h:
421         (AccessibilityMenuList):
422         * accessibility/AccessibilityNodeObject.h:
423         (AccessibilityNodeObject):
424         * accessibility/AccessibilityProgressIndicator.h:
425         (AccessibilityProgressIndicator):
426         * accessibility/AccessibilityRenderObject.h:
427         (AccessibilityRenderObject):
428         * accessibility/AccessibilityScrollView.h:
429         (AccessibilityScrollView):
430         * accessibility/AccessibilityScrollbar.h:
431         (AccessibilityScrollbar):
432         * accessibility/AccessibilitySlider.h:
433         (AccessibilitySlider):
434         * accessibility/AccessibilityTable.h:
435         (AccessibilityTable):
436         * accessibility/AccessibilityTableCell.h:
437         (AccessibilityTableCell):
438         * accessibility/AccessibilityTableRow.h:
439         (AccessibilityTableRow):
440
441 2012-08-03  Abhishek Arya  <inferno@chromium.org>
442
443         Regression(r124564): Wrong inlineChildrenBlock->hasLayer() computed in RenderBlock::removeChild.
444         https://bugs.webkit.org/show_bug.cgi?id=90800
445
446         Reviewed by Eric Seidel.
447
448         r124564 reversed the sequence of setStyle and removeChildNode calls, but failed to cache the value
449         of inlineChildrenBlock->hasLayer(). So, it will be null when the layer is removed from parent in setStyle.
450         Fixed by the caching the bool value. 
451
452         Covered by existing test fast/block/layer-not-removed-from-parent-crash.html.
453
454         * rendering/RenderBlock.cpp:
455         (WebCore::RenderBlock::removeChild):
456
457 2012-08-03  Mario Sanchez Prada  <msanchez@igalia.com>
458
459         [GTK] Add a new and reusable enchant-based spellchecker in WebCore
460         https://bugs.webkit.org/show_bug.cgi?id=90269
461
462         Reviewed by Martin Robinson.
463
464         Move enchant specific code down to WebCore, into a new class
465         TextCheckerEnchant, that we can use from WK1 and WK2.
466
467         * GNUmakefile.am: Add flags to handle the SPELLCHECK feature.
468         * GNUmakefile.list.am: Added new files.
469         * platform/text/gtk/TextCheckerEnchant.cpp: Added.
470         (getAvailableDictionariesCallback):
471         (TextCheckerEnchant::TextCheckerEnchant):
472         (TextCheckerEnchant::~TextCheckerEnchant):
473         (TextCheckerEnchant::ignoreWord):
474         (TextCheckerEnchant::learnWord):
475         (TextCheckerEnchant::checkSpellingOfString):
476         (TextCheckerEnchant::getGuessesForWord):
477         (TextCheckerEnchant::updateSpellCheckingLanguages):
478         (TextCheckerEnchant::freeEnchantBrokerDictionaries):
479         * platform/text/gtk/TextCheckerEnchant.h: Added.
480         (WebCore):
481         (TextCheckerEnchant):
482         (WebCore::TextCheckerEnchant::create):
483
484 2012-08-03  Kwang Yul Seo  <skyul@company100.net>
485
486         Unreviewed r124536 followup, fix the assertion error on Chromium.
487
488         * html/parser/HTMLTreeBuilder.cpp:
489         (WebCore::HTMLTreeBuilder::callTheAdoptionAgency):
490
491 2012-08-03  Ilya Tikhonovsky  <loislo@chromium.org>
492
493         Web Inspector: simple replace objectType with ownerObjectType in NMI code.
494         https://bugs.webkit.org/show_bug.cgi?id=93001
495
496         Reviewed by Yury Semikhatsky.
497
498         In all the cases when we are visiting members, objectType field is actually the object type of the member's owner object.
499
500         * dom/MemoryInstrumentation.h:
501         (WebCore::MemoryInstrumentation::InstrumentedPointer::InstrumentedPointer):
502         (InstrumentedPointer):
503         (WebCore::MemoryInstrumentation::addObject):
504         (WebCore::MemoryInstrumentation::addInstrumentedObject):
505         (WebCore::MemoryInstrumentation::addRawBuffer):
506         (WebCore::MemoryInstrumentation::OwningTraits::addInstrumentedObject):
507         (WebCore::MemoryInstrumentation::OwningTraits::addObject):
508         (WebCore::MemoryObjectInfo::MemoryObjectInfo):
509         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
510         (WebCore::MemoryInstrumentation::addObjectImpl):
511         (WebCore::MemoryInstrumentation::addHashMap):
512         (WebCore::MemoryInstrumentation::addHashSet):
513         (WebCore::MemoryInstrumentation::addInstrumentedCollection):
514         (WebCore::MemoryInstrumentation::addListHashSet):
515         (WebCore::MemoryInstrumentation::addVector):
516         (WebCore::::process):
517
518 2012-08-02  Ilya Tikhonovsky  <loislo@chromium.org>
519
520         Web Inspector: extend test coverage for nmi code and fix 2 bugs.
521         https://bugs.webkit.org/show_bug.cgi?id=92994
522
523         Reviewed by Yury Semikhatsky.
524
525         1) owner object type propagation.
526         If a class with object-type DOM has an instrumented member with object-type Other then it has to be recorded as DOM.
527         Sample: We have SharedBuffer class and we don't know the object-type for it but we know that it is owned by an object with object-type CachedResourceImage.
528
529         2) the first member of an instrumented non virtual class was skipped even if it was reported properly.
530         it happened because the first member has the same address as it's owner
531
532         * dom/MemoryInstrumentation.h:
533         (WebCore::MemoryInstrumentation::addRootObject):
534         (WebCore::MemoryInstrumentation::InstrumentedPointer::InstrumentedPointer):
535         (InstrumentedPointer):
536         (WebCore::MemoryInstrumentation::addInstrumentedObject):
537         (MemoryInstrumentation):
538         (WebCore::MemoryInstrumentation::OwningTraits::addInstrumentedObject):
539         (WebCore::MemoryObjectInfo::MemoryObjectInfo):
540         (WebCore::MemoryObjectInfo::reportObjectInfo):
541         (WebCore::MemoryClassInfo::addInstrumentedMember):
542         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
543         (WebCore::MemoryInstrumentation::addObjectImpl):
544         (WebCore::MemoryInstrumentation::addInstrumentedCollection):
545         (WebCore::::process):
546
547 2012-08-03  Kentaro Hara  <haraken@chromium.org>
548
549         [V8] Make v8NonStringValueToWebCoreString a static method
550         https://bugs.webkit.org/show_bug.cgi?id=93066
551
552         Reviewed by Adam Barth.
553
554         v8NonStringValueToWebCoreString() and v8NonStringValueToAtomicWebCoreString()
555         are not intended to be used from outside V8Binding.cpp.
556         They should be static methods.
557
558         No tests. No change in behavior.
559
560         * bindings/v8/V8Binding.cpp:
561         (WebCore::v8NonStringValueToWebCoreString):
562         (WebCore):
563         (WebCore::v8NonStringValueToAtomicWebCoreString):
564         * bindings/v8/V8Binding.h:
565         (WebCore::v8StringToWebCoreString):
566         (WebCore::v8StringToAtomicWebCoreString):
567
568 2012-08-02  Abhishek Arya  <inferno@chromium.org>
569
570         Crash due to layer not removed from parent for anonymous block.
571         https://bugs.webkit.org/show_bug.cgi?id=90800
572
573         Reviewed by Kent Tamura.
574
575         Reverse the order of setStyle and removeChildNode calls. This ensures that setting the style
576         properly removes its layer from the parent in RenderBoxModelObject::styleDidChange. Calling
577         removeChildNode before calling setStyle is problematic since the parent layer never gets
578         notified.
579
580         Test: fast/block/layer-not-removed-from-parent-crash.html
581
582         * rendering/RenderBlock.cpp:
583         (WebCore::RenderBlock::removeChild):
584
585 2012-08-02  Adam Barth  <abarth@webkit.org>
586
587         V8Proxy::retrieveFrameFor*Context are used only by BindingState and should be removed as separate functions
588         https://bugs.webkit.org/show_bug.cgi?id=93049
589
590         Reviewed by Eric Seidel.
591
592         No one calls these functions directly anymore. This patch removes them
593         from V8Proxy and inlines their logic into BindingState.cpp.
594
595         * bindings/v8/BindingState.cpp:
596         (WebCore::activeContext):
597         (WebCore):
598         (WebCore::activeWindow):
599         (WebCore::activeFrame):
600         (WebCore::firstFrame):
601         (WebCore::currentFrame):
602         * bindings/v8/V8Proxy.cpp:
603         * bindings/v8/V8Proxy.h:
604         (V8Proxy):
605
606 2012-08-02  Yoshifumi Inoue  <yosin@chromium.org>
607
608         Make order of attribute/method in HTMLTrackElement.idl as same as specification
609         https://bugs.webkit.org/show_bug.cgi?id=80102
610
611         Reviewed by Kentaro Hara.
612
613         No new tests. This patch doesn't change behavior.
614
615         * html/HTMLTrackElement.idl: Reorder attribute/method position.
616
617 2012-08-02  Kent Tamura  <tkent@chromium.org>
618
619         Fix crashes for <input> and <textarea> with display:run-in.
620         https://bugs.webkit.org/show_bug.cgi?id=87300
621
622         Reviewed by Abhishek Arya.
623
624         Introduce RenderObject::canBeReplacedWithInlineRunIn, and renderers which
625         should not be run-in override it so that it returns false.
626
627         Test: fast/runin/input-text-runin.html
628               fast/runin/textarea-runin.html
629
630         * rendering/RenderBlock.cpp:
631         (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
632         Checks canBeReplacedWithInlineRunIn instead of checking tag names.
633         * rendering/RenderFileUploadControl.cpp:
634         (WebCore::RenderFileUploadControl::canBeReplacedWithInlineRunIn):
635         Added. Disallow run-in.
636         * rendering/RenderFileUploadControl.h:
637         (RenderFileUploadControl): Declare canBeReplacedWithInlineRunIn.
638         * rendering/RenderListBox.cpp:
639         (WebCore::RenderListBox::canBeReplacedWithInlineRunIn):
640         Added. Disallow run-in. This is not a behavior change.
641         * rendering/RenderListBox.h:
642         (RenderListBox): Declare canBeReplacedWithInlineRunIn.
643         * rendering/RenderMenuList.cpp:
644         (WebCore::RenderMenuList::canBeReplacedWithInlineRunIn):
645         Added. Disallow run-in. This is not a behavior change.
646         * rendering/RenderMenuList.h:
647         (RenderMenuList): Declare canBeReplacedWithInlineRunIn.
648         * rendering/RenderObject.cpp:
649         (WebCore::RenderObject::canBeReplacedWithInlineRunIn):
650         Added. Allow run-in by default.
651         * rendering/RenderObject.h:
652         (RenderObject): Declare canBeReplacedWithInlineRunIn.
653         * rendering/RenderProgress.cpp:
654         (WebCore::RenderProgress::canBeReplacedWithInlineRunIn):
655         Added. Disallow run-in. This is not a behavior change.
656         * rendering/RenderProgress.h:
657         (RenderProgress): Declare canBeReplacedWithInlineRunIn.
658         * rendering/RenderSlider.cpp:
659         (WebCore::RenderSlider::canBeReplacedWithInlineRunIn):
660         Added. Disallow run-in.
661         * rendering/RenderSlider.h:
662         (RenderSlider): Declare canBeReplacedWithInlineRunIn.
663         * rendering/RenderTextControl.cpp:
664         (WebCore::RenderTextControl::canBeReplacedWithInlineRunIn):
665         Added. Disallow run-in.
666         * rendering/RenderTextControl.h:
667         (RenderTextControl): Declare canBeReplacedWithInlineRunIn.
668
669 2012-08-02  Kihong Kwon  <kihong.kwon@samsung.com>
670
671         [EFL] Fix wrong assigned value of BatteryStatus
672         https://bugs.webkit.org/show_bug.cgi?id=93058
673
674         Reviewed by Kentaro Hara.
675
676         There is a wrong change in the bug 92964.
677         property variable have to be used after assigned value in the setBatteryClient.
678
679         * platform/efl/BatteryProviderEfl.cpp:
680         (WebCore::BatteryProviderEfl::setBatteryClient):
681
682 2012-08-02  Arvid Nilsson  <anilsson@rim.com>
683
684         [BlackBerry] Add default implementation of GraphicsLayerClient::contentsVisible()
685         https://bugs.webkit.org/show_bug.cgi?id=93036
686
687         Reviewed by George Staikos.
688
689         Returning true by default would cause memory usage to balloon, because
690         the LayerTiler would believe every tile is visible and always needs to
691         be rendered. Instead, we choose to return false by default, relying
692         entirely on reactive rendering through render jobs.
693
694         However this revealed a subtle bug. If the entire layer was invalidated
695         every frame, checkerboard would never resolve with this default
696         implementation.
697
698         Fixed by not clearing render jobs when the entire layer is invalidated,
699         thus making us robust against an incomplete contentsVisible
700         implementation.
701
702         Also removed dead code related to the deprecated
703         LayerTiler::m_tilesWebKitThread mechanism, which has been replaced by
704         the implicit visibility management resulting from render jobs.
705
706         With m_tilesWebKitThread out of the way, rename m_tilesCompositingThread
707         to be simply m_tiles.
708
709         PR 187458
710
711         This is not currently testable using BlackBerry testing infrastructure.
712
713         * platform/graphics/GraphicsLayerClient.h:
714         (WebCore::GraphicsLayerClient::contentsVisible): Gets a default implementation instead of being pure virtual.
715         * platform/graphics/blackberry/LayerTile.cpp:
716         (WebCore::LayerTile::LayerTile): Merged LayerTileData into LayerTile now that m_tilesWebKitThread is gone.
717         * platform/graphics/blackberry/LayerTile.h:
718         (LayerTile):
719         * platform/graphics/blackberry/LayerTiler.cpp:
720         (WebCore::LayerTiler::~LayerTiler):
721         (WebCore::LayerTiler::updateTextureContentsIfNeeded): Bug fix to make us robust against the new default implementation of GraphicsLayerClient::contentsVisible()
722         (WebCore::LayerTiler::shouldPerformRenderJob):
723         (WebCore::LayerTiler::layerVisibilityChanged):
724         (WebCore::LayerTiler::uploadTexturesIfNeeded):
725         (WebCore::LayerTiler::drawTexturesInternal):
726         (WebCore::LayerTiler::deleteTextures):
727         (WebCore::LayerTiler::pruneTextures):
728         (WebCore::LayerTiler::bindContentsTexture):
729         * platform/graphics/blackberry/LayerTiler.h:
730         (LayerTiler):
731
732 2012-08-02  Keishi Hattori  <keishi@webkit.org>
733
734         Slider should snap to datalist tick marks
735         https://bugs.webkit.org/show_bug.cgi?id=92640
736
737         Reviewed by Kent Tamura.
738
739         Input type=range slider snaps to datalist tick marks.
740
741         Test: fast/forms/datalist/range-snap-to-datalist.html
742
743         * html/HTMLInputElement.cpp:
744         (WebCore::HTMLInputElement::findClosestTickMarkValue): Just calls InputType::findClosestTickMarkValue.
745         (WebCore):
746         * html/HTMLInputElement.h:
747         (HTMLInputElement):
748         * html/InputType.cpp:
749         (WebCore):
750         (WebCore::InputType::findClosestTickMarkValue): Overridden by RangeInputType.
751         * html/InputType.h:
752         (InputType):
753         * html/RangeInputType.cpp:
754         (WebCore::RangeInputType::RangeInputType):
755         (WebCore):
756         (WebCore::RangeInputType::listAttributeTargetChanged): Mark m_tickMarkValues as dirty.
757         (WebCore::decimalCompare):
758         (WebCore::RangeInputType::updateTickMarkValues): Sets m_tickMarkValues to a list of sorted valid datalist values.
759         (WebCore::RangeInputType::findClosestTickMarkValue): Finds closest tick mark value to a given value.
760         * html/RangeInputType.h:
761         (RangeInputType):
762         * html/shadow/SliderThumbElement.cpp:
763         (WebCore):
764         (WebCore::SliderThumbElement::setPositionFromPoint): Snaps to the closest tick mark value if it is within a certain distance.
765
766 2012-08-02  Ryuan Choi  <ryuan.choi@samsung.com>
767
768         [EFL] Crash while loading plugin after r121467
769         https://bugs.webkit.org/show_bug.cgi?id=92943
770
771         Reviewed by Laszlo Gombos.
772
773         r121467 replaced POSIX dlopen to helpers in eina_module, but some codes
774         are not changed.
775
776         No new tests, behavior has not changed.
777
778         * plugins/efl/PluginPackageEfl.cpp:
779         (WebCore::PluginPackage::fetchInfo):
780         Changes dlsym to eina_module_symbol_get to follow changes of r121467.
781
782 2012-08-02  Adam Barth  <abarth@webkit.org>
783
784         V8 bindings code that tries to find its context should use BindingState functions rather than V8Proxy
785         https://bugs.webkit.org/show_bug.cgi?id=93038
786
787         Reviewed by Eric Seidel.
788
789         After this patch, most code in the V8 bindings that tries to determine
790         it's "context" goes through BindingState.h rather than V8Proxy. This
791         patch is a step towards unifying all these code paths.
792
793         * bindings/scripts/CodeGeneratorV8.pm:
794         (GenerateNamedConstructorCallback):
795         * bindings/v8/BindingState.cpp:
796         (WebCore::currentFrame):
797         (WebCore):
798         * bindings/v8/BindingState.h:
799         (WebCore):
800         * bindings/v8/ScriptController.cpp:
801         (WebCore::ScriptController::retrieveFrameForEnteredContext):
802         (WebCore::ScriptController::retrieveFrameForCurrentContext):
803         * bindings/v8/V8DOMWindowShell.cpp:
804         (WebCore::v8UncaughtExceptionHandler):
805         * bindings/v8/V8Proxy.cpp:
806         (WebCore::V8Proxy::reportUnsafeAccessTo):
807         * bindings/v8/V8Proxy.h:
808         (V8Proxy):
809         * bindings/v8/V8Utilities.cpp:
810         (WebCore::getScriptExecutionContext):
811         * bindings/v8/custom/V8AudioContextCustom.cpp:
812         (WebCore::V8AudioContext::constructorCallback):
813         * bindings/v8/custom/V8DOMWindowCustom.cpp:
814         (WebCore::handlePostMessageCallback):
815         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
816         (WebCore::V8HTMLDocument::writeCallback):
817         (WebCore::V8HTMLDocument::writelnCallback):
818         (WebCore::V8HTMLDocument::openCallback):
819         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
820         (WebCore::v8HTMLImageElementConstructorCallback):
821
822 2012-08-02  Sheriff Bot  <webkit.review.bot@gmail.com>
823
824         Unreviewed, rolling out r124540.
825         http://trac.webkit.org/changeset/124540
826         https://bugs.webkit.org/show_bug.cgi?id=93055
827
828         Broke compile on Chromium Win bot (Requested by dimich on
829         #webkit).
830
831         * Modules/indexeddb/IDBBackingStore.h:
832         (IDBBackingStore):
833         * Modules/indexeddb/IDBCallbacks.h:
834         (IDBCallbacks):
835         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
836         (WebCore::IDBDatabaseBackendImpl::PendingOpenCall::PendingOpenCall):
837         (WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
838         (WebCore::IDBDatabaseBackendImpl::openInternal):
839         (WebCore::IDBDatabaseBackendImpl::metadata):
840         (WebCore::IDBDatabaseBackendImpl::setVersion):
841         (WebCore::IDBDatabaseBackendImpl::transactionFinished):
842         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
843         (WebCore::IDBDatabaseBackendImpl::registerFrontendCallbacks):
844         (WebCore::IDBDatabaseBackendImpl::deleteDatabase):
845         (WebCore::IDBDatabaseBackendImpl::close):
846         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
847         (IDBDatabaseBackendImpl):
848         * Modules/indexeddb/IDBDatabaseCallbacks.h:
849         (IDBDatabaseCallbacks):
850         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
851         (WebCore::IDBFactoryBackendImpl::open):
852         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
853         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
854         (WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
855         (WebCore::IDBLevelDBBackingStore::deleteDatabase):
856         * Modules/indexeddb/IDBLevelDBBackingStore.h:
857         (IDBLevelDBBackingStore):
858         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
859         (WebCore::IDBTransactionBackendImpl::commit):
860
861 2012-08-02  Arvid Nilsson  <anilsson@rim.com>
862
863         [BlackBerry] Upstream GraphicsLayerClient::contentsVisible()
864         https://bugs.webkit.org/show_bug.cgi?id=93040
865
866         Reviewed by George Staikos.
867
868         Our LayerTiler uses both proactive and reactive rendering to populate
869         tiles. If contentsVisible() is accurate, it will cause the right tiles
870         to be rendered. Failing that, when a dirty tile is found to be visible
871         on the compositing thread, a render job is scheduled.
872
873         This is not currently testable using BlackBerry testing infrastructure.
874
875         * platform/graphics/GraphicsLayerClient.h:
876         (GraphicsLayerClient): New BlackBerry-specific method "contentsVisible" added.
877         * rendering/RenderLayerBacking.cpp:
878         (WebCore):
879         (WebCore::RenderLayerBacking::contentsVisible): BlackBerry-specific implementation.
880
881 2012-08-02  Alexandre Elias  <aelias@google.com>
882
883         [chromium] deviceViewportSize cleanup
884         https://bugs.webkit.org/show_bug.cgi?id=92794
885
886         Reviewed by Adrienne Walker.
887
888         In the future, CSS layout size will become increasingly disassociated
889         from physical device size, and it will become impossible to infer one
890         from the other inside the compositor.  Therefore, this patch allows
891         deviceViewportSize to be explicitly passed in by the outside client.
892
893         I also renamed the existing viewportSize field to "layoutViewportSize"
894         for clarity, and converted its uses to deviceViewportSize since
895         that is more appropriate.
896
897         I had to add some default-value scaffolding to WebLayerTreeView in
898         order to avoid breaking ui/compositor.  We can delete it once that's
899         updated.
900
901         No new tests (covered by existing tests).
902
903         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
904         (WebCore::CCLayerTreeHost::finishCommitOnImplThread):
905         (WebCore::CCLayerTreeHost::setViewportSize):
906         (WebCore::CCLayerTreeHost::updateLayers):
907         (WebCore::CCLayerTreeHost::setDeviceScaleFactor):
908         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
909         (CCLayerTreeHost):
910         (WebCore::CCLayerTreeHost::layoutViewportSize):
911         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
912         (WebCore::CCLayerTreeHostImpl::canDraw):
913         (WebCore::CCLayerTreeHostImpl::startPageScaleAnimation):
914         (WebCore::CCLayerTreeHostImpl::setViewportSize):
915         (WebCore::CCLayerTreeHostImpl::setDeviceScaleFactor):
916         (WebCore::CCLayerTreeHostImpl::updateMaxScrollPosition):
917         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
918         (CCLayerTreeHostImpl):
919         (WebCore::CCLayerTreeHostImpl::layoutViewportSize):
920
921 2012-08-02  Adam Barth  <abarth@webkit.org>
922
923         V8Proxy::currentContext() doesn't do anything and should be removed
924         https://bugs.webkit.org/show_bug.cgi?id=93041
925
926         Reviewed by Eric Seidel.
927
928         It's just a wrapper for GetCurrent().
929
930         * bindings/v8/DateExtension.cpp:
931         (WebCore::DateExtension::setAllowSleep):
932         * bindings/v8/V8NPUtils.cpp:
933         (WebCore::convertV8ObjectToNPVariant):
934         * bindings/v8/V8Proxy.cpp:
935         (WebCore::V8Proxy::retrieve):
936         (WebCore::V8Proxy::mainWorldContext):
937         * bindings/v8/V8Proxy.h:
938         (V8Proxy):
939         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
940         (WebCore::getJSListenerFunctions):
941
942 2012-08-02  David Grogan  <dgrogan@chromium.org>
943
944         IndexedDB: Core upgradeneeded logic
945         https://bugs.webkit.org/show_bug.cgi?id=92558
946
947         Reviewed by Ojan Vafai.
948
949         This is the backend webkit logic needed for integer versions. The rest
950         is in https://bugs.webkit.org/show_bug.cgi?id=89505.
951
952         I tried to make use of the existing processPendingCalls and added two
953         more queues, pendingOpenWithVersionCalls and
954         pendingSecondHalfOpenWithVersionCalls. The "second half" refers to
955         how there are two events that need to be fired in response to an
956         open-with-version call. The "second half" queue holds the open
957         requests that should immediately follow the caller's upgradeneeded
958         handler.
959
960         No new tests, there are so many they are in their own patch:
961         https://bugs.webkit.org/show_bug.cgi?id=92560
962
963         Though this patch doesn't change any expected behavior anyway, lack of
964         regressions is what we're hoping for here.
965
966         * Modules/indexeddb/IDBBackingStore.h:
967         (IDBBackingStore):
968         * Modules/indexeddb/IDBCallbacks.h:
969         (WebCore::IDBCallbacks::onBlocked):
970         (WebCore::IDBCallbacks::onUpgradeNeeded):
971         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
972         (IDBDatabaseBackendImpl::PendingOpenCall):
973         (IDBDatabaseBackendImpl::PendingOpenWithVersionCall):
974         (WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::create):
975         (WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::callbacks):
976         (WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::version):
977         (WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::PendingOpenWithVersionCall):
978         (WebCore):
979         (WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
980         (WebCore::IDBDatabaseBackendImpl::openInternal):
981         (WebCore::IDBDatabaseBackendImpl::metadata):
982         (WebCore::IDBDatabaseBackendImpl::setVersion):
983         (WebCore::IDBDatabaseBackendImpl::setIntVersionInternal):
984         (WebCore::IDBDatabaseBackendImpl::transactionFinished):
985         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndEventsFired):
986         When an upgradeneeded event is fired in response to an
987         open-with-version call, the version change transaction must receive its
988         complete event before processPendingCalls fires a success event at
989         IDBOpenDBRequest. In the future this should probably be changed
990         instead to transactionFinishedAndAbortFired and
991         transactionFinishedAndCompleteFired so that we'll know to fire a
992         success or error event at IDBOpenDBRequest. Currently, instead of
993         firing error when there's an abort, we don't fire anything.
994
995         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
996         Now that this is called after a connection is opened, we unfortunately
997         lose the invariant that there is only one existing connection when this
998         is called, but nothing inside this function actually relied on that.
999         Additionally, the secondHalfOpen calls only ever need to be serviced
1000         in one place: right after a version change transaction completes, so
1001         it could be moved out of here.
1002
1003         (WebCore::IDBDatabaseBackendImpl::registerFrontendCallbacks):
1004         Now that setVersion and deleteDatabase calls are queued up behind
1005         secondHalfOpen calls, we have to service those queues when
1006         secondHalfOpen calls complete, which is here.  So call
1007         processPendingCalls().
1008
1009         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
1010         (WebCore::IDBDatabaseBackendImpl::openConnectionWithVersion):
1011         (WebCore::IDBDatabaseBackendImpl::deleteDatabase):
1012         (WebCore::IDBDatabaseBackendImpl::close):
1013         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
1014         (IDBDatabaseBackendImpl):
1015         * Modules/indexeddb/IDBDatabaseCallbacks.h:
1016         (WebCore::IDBDatabaseCallbacks::onVersionChange):
1017         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
1018         (WebCore::IDBFactoryBackendImpl::open):
1019         This is refactored some so that the call to openConection{WithVersion}
1020         happens once, at the end.
1021
1022         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
1023         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
1024         (WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
1025         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
1026         (WebCore):
1027         (WebCore::IDBLevelDBBackingStore::deleteDatabase):
1028         * Modules/indexeddb/IDBLevelDBBackingStore.h:
1029         (IDBLevelDBBackingStore):
1030         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
1031         (WebCore::IDBTransactionBackendImpl::commit):
1032         See above comments about transactionFinishedAndEventsFired. I tried
1033         moving the call to transactionFinished after the events were fired but
1034         that failed some asserts. But changing those asserts is still an
1035         alternative to splitting up transactionFinished as is done here.
1036
1037 2012-08-02  Rob Buis  <rwlbuis@webkit.org>
1038
1039         SVG text selection doesn't work with hyperlinked text
1040         https://bugs.webkit.org/show_bug.cgi?id=29166
1041
1042         Reviewed by Eric Seidel.
1043
1044         Cleanup SVGAElement. There is no need to test for middle mouse button here, this
1045         is handled elsewhere, so remove isMiddleMouseButtonEvent. Similarly handleLinkClick
1046         is not used anymore by HTMLAnchorElement, remove it. Finally, _self indeed is not needed.
1047
1048         No new tests, since no change in behaviour.
1049
1050         * WebCore.order:
1051         * html/HTMLAnchorElement.cpp:
1052         * html/HTMLAnchorElement.h:
1053         (WebCore):
1054         * svg/SVGAElement.cpp:
1055         (WebCore::SVGAElement::defaultEventHandler):
1056
1057 2012-08-02  Kwang Yul Seo  <skyul@company100.net>
1058
1059         Move causesFosterParenting() to HTMLStackItem
1060         https://bugs.webkit.org/show_bug.cgi?id=93048
1061
1062         Reviewed by Adam Barth.
1063
1064         Changed to share causesFosterParenting() between HTMLTreeBuilder and HTMLConstructionSite
1065         by moving this function to HTMLStackItem.
1066
1067         No functional change, so no new tests.
1068
1069         * html/parser/HTMLConstructionSite.cpp:
1070         (WebCore::HTMLConstructionSite::shouldFosterParent):
1071         * html/parser/HTMLStackItem.h:
1072         (WebCore::HTMLStackItem::causesFosterParenting):
1073         (HTMLStackItem):
1074         * html/parser/HTMLTreeBuilder.cpp:
1075         (WebCore::HTMLTreeBuilder::callTheAdoptionAgency):
1076
1077 2012-08-02  Kwang Yul Seo  <skyul@company100.net>
1078
1079         Read tag names and attributes from the saved tokens in HTMLTreeBuilder::callTheAdoptionAgency(AtomicHTMLToken*)
1080         https://bugs.webkit.org/show_bug.cgi?id=93047
1081
1082         Reviewed by Adam Barth.
1083
1084         This is a follow-up patch for r123577.
1085         Changed to retrieve the stack item of commonAncestor and read the local name from the saved token.
1086
1087         No new tests, covered by existing tests.
1088
1089         * html/parser/HTMLTreeBuilder.cpp:
1090         (WebCore::HTMLTreeBuilder::callTheAdoptionAgency):
1091
1092 2012-08-02  Vincent Scheib  <scheib@chromium.org>
1093
1094         Remove old Pointer Lock API.
1095         https://bugs.webkit.org/show_bug.cgi?id=88892
1096
1097         Reviewed by Adam Barth.
1098
1099         Removing the old Pointer Lock API as one of the final cleanup
1100         changes for the Update to Fullscreen style locking Spec meta
1101         bug https://bugs.webkit.org/show_bug.cgi?id=84402.
1102
1103         This change primarily removes idl, access in navigator,
1104         one event, and supporting infrastructure in page/PointerLock.
1105
1106         In PointerLockController changes were already noted clearly with
1107         TODOs differentiating old and new api sections.
1108
1109         Test: pointer-lock/pointerlockchange-event-on-lock-lost.html
1110
1111         * WebCore.gypi:
1112         * dom/Element.cpp:
1113         (WebCore::Element::webkitRequestPointerLock):
1114         * dom/EventNames.h:
1115         (WebCore):
1116         * page/Navigator.cpp:
1117         * page/Navigator.h:
1118         (WebCore):
1119         (Navigator):
1120         * page/Navigator.idl:
1121         * page/PointerLock.cpp: Removed.
1122         * page/PointerLock.h: Removed.
1123         * page/PointerLock.idl: Removed.
1124         * page/PointerLockController.cpp:
1125         (WebCore::PointerLockController::requestPointerLock):
1126         (WebCore::PointerLockController::didAcquirePointerLock):
1127         (WebCore::PointerLockController::didNotAcquirePointerLock):
1128         (WebCore::PointerLockController::didLosePointerLock):
1129         * page/PointerLockController.h:
1130         (PointerLockController):
1131
1132 2012-08-02  Ryosuke Niwa  <rniwa@webkit.org>
1133
1134         scripts in formaction should be stripped upon paste
1135         https://bugs.webkit.org/show_bug.cgi?id=92298
1136
1137         Reviewed by Eric Seidel.
1138
1139         Strip formaction attribute values when the URL is of javascript protocol.
1140
1141         Test: editing/pasteboard/paste-noscript-xhtml.html
1142               editing/pasteboard/paste-noscript.html
1143
1144         * dom/Element.cpp:
1145         (WebCore::isAttributeToRemove): Explicitly compare with href and nohref instead of comparing
1146         the ends of strings since comparing two AtomicString is much faster.
1147
1148 2012-08-02  Elliott Sprehn  <esprehn@gmail.com>
1149
1150         Built in quotes don't use lang attribute
1151         https://bugs.webkit.org/show_bug.cgi?id=92918
1152
1153         Reviewed by Alexey Proskuryakov.
1154
1155         Previously even though there was a table in RenderQuote of languages mapped
1156         to quotes we always used basic quotes. This patch removes the broken tree
1157         walking and uses Element::computeInheritedLanguage fixing this.
1158
1159         Tests: fast/css-generated-content/quotes-lang-expected.html
1160                fast/css-generated-content/quotes-lang.html
1161                fast/css-generated-content/quotes-xml-lang-expected.html
1162                fast/css-generated-content/quotes-xml-lang.html
1163
1164         * rendering/RenderQuote.cpp:
1165         (WebCore::RenderQuote::originalText):
1166         (WebCore::RenderQuote::quotesData): New method that determines the right QuotesData to use.
1167         (WebCore):
1168         * rendering/RenderQuote.h:
1169         (RenderQuote):
1170
1171 2012-08-02  Adam Barth  <abarth@webkit.org>
1172
1173         Add back a header I mistakenly removed in my previous commit.
1174
1175         * WebCore.xcodeproj/project.pbxproj:
1176
1177 2012-08-02  Adrienne Walker  <enne@google.com>
1178
1179         [chromium] Remove dependency on Scrollbar.h from ScrollbarLayerChromium
1180         https://bugs.webkit.org/show_bug.cgi?id=93024
1181
1182         Reviewed by James Robinson.
1183
1184         Change part enum from the Scrollbar version to WebScrollbar's.
1185
1186         Tested by composited layout tests.
1187
1188         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
1189         (WebCore::ScrollbarBackgroundPainter::create):
1190         (WebCore::ScrollbarBackgroundPainter::ScrollbarBackgroundPainter):
1191         (ScrollbarBackgroundPainter):
1192         (WebCore::ScrollbarLayerChromium::createTextureUpdaterIfNeeded):
1193
1194 2012-08-02  Adam Barth  <abarth@webkit.org>
1195
1196         BindingSecurityBase serves no purpose and should be removed
1197         https://bugs.webkit.org/show_bug.cgi?id=93025
1198
1199         Reviewed by Eric Seidel.
1200
1201         Now that we don't use templates in the generic bindings, we can merge
1202         BindingSecurity and BindingSecurityBase. This patch also removes some
1203         functions that are no longer used (and reduces the number of
1204         #includes).
1205
1206         No behavior change.
1207
1208         * GNUmakefile.list.am:
1209         * WebCore.gypi:
1210         * bindings/generic/BindingSecurity.h:
1211         (WebCore):
1212         (BindingSecurity):
1213         * bindings/generic/BindingSecurityBase.cpp: Removed.
1214         * bindings/generic/BindingSecurityBase.h: Removed.
1215         * bindings/v8/V8Binding.h:
1216         * bindings/v8/V8Utilities.cpp:
1217         * bindings/v8/custom/V8MutationObserverCustom.cpp:
1218
1219 2012-08-02  Ryosuke Niwa  <rniwa@webkit.org>
1220
1221         Let XCode have its own away and also sort the files.
1222
1223         * WebCore.xcodeproj/project.pbxproj:
1224
1225 2012-08-02  Tien-Ren Chen  <trchen@chromium.org>
1226
1227         [chromium] Add CCScrollbarAnimationController class for compositor scrollbar animation
1228         https://bugs.webkit.org/show_bug.cgi?id=91688
1229
1230         Reviewed by Adrienne Walker.
1231
1232         Add CCScrollbarAnimationController that serves as the middle man
1233         between the scrolling layer and scrollbar layer. Now all scroll offset
1234         information are pushed through the controller, and individual platform
1235         can provide specialized controller for extra processing.
1236
1237         A basic fadeout controller for Android scrollbar is included.
1238
1239         New test: ScrollbarLayerChromiumTest.scrollOffsetSynchronization
1240                   CCScrollbarAnimationControllerLinearFade.*
1241
1242         * WebCore.gypi:
1243         * page/FrameView.cpp:
1244         (WebCore::FrameView::calculateScrollbarModesForLayout):
1245         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1246         (WebCore::createScrollbarLayer):
1247         * platform/graphics/chromium/TreeSynchronizer.cpp:
1248         (WebCore::TreeSynchronizer::synchronizeTreeRecursive):
1249         (WebCore::TreeSynchronizer::updateScrollbarLayerPointersRecursive):
1250         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1251         (WebCore::CCLayerImpl::scrollBy):
1252         (WebCore::CCLayerImpl::setMaxScrollPosition):
1253         (WebCore):
1254         (WebCore::CCLayerImpl::horizontalScrollbarLayer):
1255         (WebCore::CCLayerImpl::setHorizontalScrollbarLayer):
1256         (WebCore::CCLayerImpl::verticalScrollbarLayer):
1257         (WebCore::CCLayerImpl::setVerticalScrollbarLayer):
1258         * platform/graphics/chromium/cc/CCLayerImpl.h:
1259         (WebCore):
1260         (CCLayerImpl):
1261         (WebCore::CCLayerImpl::scrollbarAnimationController):
1262         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1263         (WebCore::CCLayerTreeHostImpl::animate):
1264         (WebCore::CCLayerTreeHostImpl::pinchGestureBegin):
1265         (WebCore::CCLayerTreeHostImpl::pinchGestureUpdate):
1266         (WebCore::CCLayerTreeHostImpl::pinchGestureEnd):
1267         (WebCore::CCLayerTreeHostImpl::animateScrollbars):
1268         (WebCore):
1269         (WebCore::CCLayerTreeHostImpl::animateScrollbarsRecursive):
1270         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1271         (CCLayerTreeHostImpl):
1272         * platform/graphics/chromium/cc/CCScrollbarAnimationController.cpp: Added.
1273         (WebCore):
1274         (WebCore::CCScrollbarAnimationController::create):
1275         (WebCore::CCScrollbarAnimationController::CCScrollbarAnimationController):
1276         (WebCore::CCScrollbarAnimationController::~CCScrollbarAnimationController):
1277         (WebCore::CCScrollbarAnimationController::getScrollLayerBounds):
1278         (WebCore::CCScrollbarAnimationController::updateScrollOffset):
1279         * platform/graphics/chromium/cc/CCScrollbarAnimationController.h: Added.
1280         (WebCore):
1281         (CCScrollbarAnimationController):
1282         (WebCore::CCScrollbarAnimationController::animate):
1283         (WebCore::CCScrollbarAnimationController::didPinchGestureBegin):
1284         (WebCore::CCScrollbarAnimationController::didPinchGestureUpdate):
1285         (WebCore::CCScrollbarAnimationController::didPinchGestureEnd):
1286         (WebCore::CCScrollbarAnimationController::setHorizontalScrollbarLayer):
1287         (WebCore::CCScrollbarAnimationController::horizontalScrollbarLayer):
1288         (WebCore::CCScrollbarAnimationController::setVerticalScrollbarLayer):
1289         (WebCore::CCScrollbarAnimationController::verticalScrollbarLayer):
1290         * platform/graphics/chromium/cc/CCScrollbarAnimationControllerAndroid.cpp: Added.
1291         (WebCore):
1292         (WebCore::CCScrollbarAnimationController::create):
1293         (WebCore::CCScrollbarAnimationControllerAndroid::CCScrollbarAnimationControllerAndroid):
1294         (WebCore::CCScrollbarAnimationControllerAndroid::~CCScrollbarAnimationControllerAndroid):
1295         (WebCore::CCScrollbarAnimationControllerAndroid::animate):
1296         (WebCore::CCScrollbarAnimationControllerAndroid::didPinchGestureUpdate):
1297         (WebCore::CCScrollbarAnimationControllerAndroid::didPinchGestureEnd):
1298         (WebCore::CCScrollbarAnimationControllerAndroid::updateScrollOffset):
1299         (WebCore::CCScrollbarAnimationControllerAndroid::opacityAtTime):
1300         * platform/graphics/chromium/cc/CCScrollbarAnimationControllerAndroid.h: Added.
1301         (WebCore):
1302         (CCScrollbarAnimationControllerAndroid):
1303         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
1304         (WebCore::CCScrollbarLayerImpl::CCScrollbarLayerImpl):
1305         (WebCore):
1306         (WebCore::CCScrollbarLayerImpl::CCScrollbar::value):
1307         (WebCore::CCScrollbarLayerImpl::CCScrollbar::currentPos):
1308         (WebCore::CCScrollbarLayerImpl::CCScrollbar::totalSize):
1309         (WebCore::CCScrollbarLayerImpl::CCScrollbar::maximum):
1310         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1311         (WebCore::CCScrollbarLayerImpl::orientation):
1312         (WebCore::CCScrollbarLayerImpl::setCurrentPos):
1313         (WebCore::CCScrollbarLayerImpl::setTotalSize):
1314         (WebCore::CCScrollbarLayerImpl::setMaximum):
1315         (CCScrollbarLayerImpl):
1316
1317 2012-06-15  David Barton  <dbarton@mathscribe.com>
1318
1319         MathML: nested square root symbols have varying descenders
1320         https://bugs.webkit.org/show_bug.cgi?id=43819
1321
1322         Reviewed by Eric Seidel.
1323
1324         This bug stems from the use of offsetHeight() on a renderer that's possibly a
1325         RenderInline, in getBoxModelObjectHeight() in RenderMathMLBlock.h.
1326         RenderInline::offsetHeight() actually returns linesBoundingBox().height(), which can be
1327         overly large, especially for the big STIX fonts that include a few mathematical symbols
1328         with unusually tall ascenders or descenders. A better solution for MathML in general is
1329         the CSS properties { -webkit-line-box-contain: glyphs replaced; line-height: 0; }. This
1330         gives tight glyph-based formatting in radical expressions, subscripts, superscripts,
1331         underscripts, overscripts, numerators, denominators, etc. To make this work, inline
1332         elements such as <mn> and <mi> must be wrapped inside implicit <mrow>s or just
1333         RenderMathMLBlocks, when a tight height is desired. We also replace
1334         getBoxModelObjectWidth(), which uses offsetWidth(), with contentLogicalWidth(). Finally,
1335         we enable the STIXGeneral font for use inside layout tests.
1336
1337         Tested by existing LayoutTests/mathml/presentation/ files including roots.xhtml.
1338
1339         * css/mathml.css:
1340         (math):
1341         (mtext):
1342         (mroot > * + *):
1343         (mtd):
1344         * rendering/mathml/RenderMathMLBlock.cpp:
1345         (WebCore::RenderMathMLBlock::preferredLogicalHeightAfterSizing):
1346         (WebCore::RenderMathMLBlock::baselinePosition):
1347         * rendering/mathml/RenderMathMLBlock.h:
1348         * rendering/mathml/RenderMathMLFraction.cpp:
1349         (WebCore::RenderMathMLFraction::baselinePosition):
1350         * rendering/mathml/RenderMathMLOperator.cpp:
1351         (WebCore::RenderMathMLOperator::createStackableStyle):
1352         (WebCore::RenderMathMLOperator::baselinePosition):
1353         * rendering/mathml/RenderMathMLRoot.cpp:
1354         (WebCore::RenderMathMLRoot::addChild):
1355         (WebCore::RenderMathMLRoot::computePreferredLogicalWidths):
1356         (WebCore::RenderMathMLRoot::paint):
1357         * rendering/mathml/RenderMathMLRoot.h:
1358         * rendering/mathml/RenderMathMLSquareRoot.cpp:
1359         * rendering/mathml/RenderMathMLSquareRoot.h:
1360         * rendering/mathml/RenderMathMLSubSup.cpp:
1361         (WebCore::RenderMathMLSubSup::layout):
1362         * rendering/mathml/RenderMathMLUnderOver.cpp:
1363         (WebCore::RenderMathMLUnderOver::baselinePosition):
1364         * rendering/mathml/RenderMathMLUnderOver.h:
1365
1366 2012-08-02  Adrienne Walker  <enne@google.com>
1367
1368         [chromium] Make CCScrollbarLayerImpl handle lost contexts properly
1369         https://bugs.webkit.org/show_bug.cgi?id=93021
1370
1371         Reviewed by James Robinson.
1372
1373         The resource ids that CCScrollbarLayerImpl holds onto need to be
1374         discarded during a lost context as the resource provider they came
1375         from is also destroyed.
1376
1377         Make a scrollbarGeometry function that wraps all uses of the
1378         m_geometry member to make it possible to test CCScrollbarLayerImpl
1379         without depending on WebCore.
1380
1381         Test: CCLayerTreeHostImplTest.dontUseOldResourcesAfterLostContext
1382
1383         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
1384         (WebCore::CCScrollbarLayerImpl::scrollbarGeometry):
1385         (WebCore):
1386         (WebCore::CCScrollbarLayerImpl::appendQuads):
1387         (WebCore::CCScrollbarLayerImpl::didLoseContext):
1388         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1389         (CCScrollbarLayerImpl):
1390
1391 2012-08-02  Oliver Hunt  <oliver@apple.com>
1392
1393         A few objects aren't being safely protected from GC in all cases
1394         https://bugs.webkit.org/show_bug.cgi?id=93031
1395
1396         Reviewed by Filip Pizlo.
1397
1398         I haven't seen evidence that anyone is hitting bugs due to this, but any
1399         GC error can lead to later -- hard to diagnose -- bugs if they result in
1400         resurrecting dead objects.
1401
1402         * bindings/js/JSCustomXPathNSResolver.cpp:
1403         (WebCore::JSCustomXPathNSResolver::create):
1404         (WebCore::JSCustomXPathNSResolver::JSCustomXPathNSResolver):
1405         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
1406         * bindings/js/JSCustomXPathNSResolver.h:
1407         (JSCustomXPathNSResolver):
1408         * bindings/js/JSDictionary.cpp:
1409         (WebCore::JSDictionary::tryGetProperty):
1410         * bindings/js/JSDictionary.h:
1411         (WebCore::JSDictionary::JSDictionary):
1412         (WebCore::JSDictionary::initializerObject):
1413
1414 2012-08-02  Emil A Eklund  <eae@chromium.org>
1415
1416         Range::isPointInRange incorrectly throws WRONG_DOCUMENT_ERR
1417         https://bugs.webkit.org/show_bug.cgi?id=93009
1418
1419         Reviewed by Ojan Vafai.
1420
1421         The latest working draft of the DOM4 spec has all but killed the
1422         WRONG_DOCUMENT_ERR exception. Update isPointInRange to return false
1423         instead of throwing an exception when the range and point are in
1424         different documents. This matches the Mozilla behavior.
1425
1426         Test: fast/html/range-point-in-range-for-different-documents.html
1427
1428         * dom/Range.cpp:
1429         (WebCore::Range::isPointInRange):
1430         Return false instead of throwing WRONG_DOCUMENT_ERR when the point is in
1431         a different document.
1432
1433 2012-08-02  Erik Arvidsson  <arv@chromium.org>
1434
1435         DOM4: className should be defined on Element and not on HTMLElement
1436         https://bugs.webkit.org/show_bug.cgi?id=93014
1437
1438         Reviewed by Adam Barth.
1439
1440         DOM4 specs that Element should have the className WebIDL attribute. This moves the
1441         attribute to the correct IDL file.
1442
1443         Test: fast/dom/Element/class-name.html
1444
1445         * dom/Element.idl:
1446         * html/HTMLElement.idl:
1447
1448 2012-08-02  Erik Arvidsson  <arv@chromium.org>
1449
1450         [V8] Handle case where Error.prototype returns an empty object
1451         https://bugs.webkit.org/show_bug.cgi?id=91792
1452
1453         Reviewed by Kentaro Hara.
1454
1455         In some edge cases we get an empty object back from Error.prototype.
1456
1457         No new tests. I cannot reproduce this.
1458
1459         * bindings/v8/V8BindingPerContextData.cpp:
1460         (WebCore::V8BindingPerContextData::constructorForTypeSlowCase):
1461
1462 2012-08-02  Eric Seidel  <eric@webkit.org>
1463
1464         Add back ASSERT(!needsLayout) to RenderTableSection which is now valid
1465         https://bugs.webkit.org/show_bug.cgi?id=92954
1466
1467         Unreviewed, follow-up per Mitz's request.
1468
1469         * rendering/RenderTableSection.cpp:
1470         (WebCore::RenderTableSection::paint):
1471
1472 2012-08-02  James Robinson  <jamesr@chromium.org>
1473
1474         [chromium] Remove unused includes from compositor code
1475         https://bugs.webkit.org/show_bug.cgi?id=92930
1476
1477         Reviewed by Adrienne Walker.
1478
1479         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
1480         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
1481         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1482
1483 2012-08-02  Adam Barth  <abarth@webkit.org>
1484
1485         The generic bindings shouldn't use templates
1486         https://bugs.webkit.org/show_bug.cgi?id=93016
1487
1488         Reviewed by Eric Seidel.
1489
1490         We originally created the generic bindings to share code between the
1491         JavaScriptCore and V8 bindings. However, the code came out sort of ugly
1492         because we used templates (with the idea that templates would let us
1493         use more than one scripting engine).
1494
1495         This patch rips out the templates in an attempt to make the code
1496         prettier and therefore easier to use in both V8 and JSC. I've tried to
1497         keep this patch small by remaning things mostly in place. In the next
1498         patch, I'll move a bunch of code out of headers and into cpp files.
1499
1500         No behavior change.
1501
1502         * GNUmakefile.am:
1503         * UseV8.cmake:
1504         * WebCore.gyp/WebCore.gyp:
1505         * WebCore.gypi:
1506         * WebCore.pri:
1507         * bindings/generic/BindingSecurity.h:
1508         (WebCore):
1509         (BindingSecurity):
1510         (WebCore::BindingSecurity::canAccessWindow):
1511         (WebCore::BindingSecurity::canAccessFrame):
1512         (WebCore::BindingSecurity::shouldAllowAccessToNode):
1513         (WebCore::BindingSecurity::allowPopUp):
1514         (WebCore::BindingSecurity::allowSettingFrameSrcToJavascriptUrl):
1515         (WebCore::BindingSecurity::allowSettingSrcToJavascriptURL):
1516         * bindings/generic/GenericBinding.h:
1517         (WebCore::completeURL):
1518         * bindings/scripts/CodeGeneratorV8.pm:
1519         (GenerateDomainSafeFunctionGetter):
1520         (GenerateNormalAttrGetter):
1521         (GenerateReplaceableAttrSetter):
1522         (GenerateFunctionCallback):
1523         (GenerateImplementation):
1524         * bindings/scripts/test/V8/V8Float64Array.cpp:
1525         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1526         (WebCore::TestActiveDOMObjectV8Internal::excitingFunctionCallback):
1527         (WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
1528         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1529         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1530         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1531         * bindings/scripts/test/V8/V8TestException.cpp:
1532         * bindings/scripts/test/V8/V8TestInterface.cpp:
1533         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1534         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1535         * bindings/scripts/test/V8/V8TestNode.cpp:
1536         * bindings/scripts/test/V8/V8TestObj.cpp:
1537         (WebCore::TestObjV8Internal::contentDocumentAttrGetter):
1538         (WebCore::TestObjV8Internal::getSVGDocumentCallback):
1539         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1540         * bindings/v8/BindingState.cpp: Renamed from Source/WebCore/bindings/v8/specialization/V8BindingState.cpp.
1541         (WebCore):
1542         (WebCore::BindingState::instance):
1543         (WebCore::activeWindow):
1544         (WebCore::firstWindow):
1545         (WebCore::activeFrame):
1546         (WebCore::firstFrame):
1547         (WebCore::immediatelyReportUnsafeAccessTo):
1548         * bindings/v8/BindingState.h: Renamed from Source/WebCore/bindings/v8/specialization/V8BindingState.h.
1549         (WebCore):
1550         (BindingState):
1551         * bindings/v8/ScriptController.cpp:
1552         (WebCore::ScriptController::canAccessFromCurrentOrigin):
1553         * bindings/v8/V8Binding.h:
1554         (WebCore):
1555         * bindings/v8/V8DOMWindowShell.cpp:
1556         * bindings/v8/V8Proxy.cpp:
1557         * bindings/v8/V8Utilities.cpp:
1558         (WebCore::callingOrEnteredFrame):
1559         (WebCore::completeURL):
1560         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1561         (WebCore::WindowSetTimeoutImpl):
1562         (WebCore::V8DOMWindow::eventAccessorGetter):
1563         (WebCore::V8DOMWindow::eventAccessorSetter):
1564         (WebCore::V8DOMWindow::locationAccessorSetter):
1565         (WebCore::V8DOMWindow::openerAccessorSetter):
1566         (WebCore::V8DOMWindow::addEventListenerCallback):
1567         (WebCore::V8DOMWindow::removeEventListenerCallback):
1568         (WebCore::V8DOMWindow::showModalDialogCallback):
1569         (WebCore::V8DOMWindow::openCallback):
1570         (WebCore::V8DOMWindow::namedSecurityCheck):
1571         (WebCore::V8DOMWindow::indexedSecurityCheck):
1572         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
1573         (WebCore::V8Document::locationAccessorSetter):
1574         * bindings/v8/custom/V8EntryCustom.cpp:
1575         * bindings/v8/custom/V8EntrySyncCustom.cpp:
1576         * bindings/v8/custom/V8HTMLFrameElementCustom.cpp:
1577         (WebCore::V8HTMLFrameElement::locationAccessorSetter):
1578         * bindings/v8/custom/V8HistoryCustom.cpp:
1579         (WebCore::V8History::indexedSecurityCheck):
1580         (WebCore::V8History::namedSecurityCheck):
1581         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1582         * bindings/v8/custom/V8InjectedScriptManager.cpp:
1583         (WebCore::InjectedScriptManager::canAccessInspectedWindow):
1584         * bindings/v8/custom/V8LocationCustom.cpp:
1585         (WebCore::V8Location::hashAccessorSetter):
1586         (WebCore::V8Location::hostAccessorSetter):
1587         (WebCore::V8Location::hostnameAccessorSetter):
1588         (WebCore::V8Location::hrefAccessorSetter):
1589         (WebCore::V8Location::pathnameAccessorSetter):
1590         (WebCore::V8Location::portAccessorSetter):
1591         (WebCore::V8Location::protocolAccessorSetter):
1592         (WebCore::V8Location::searchAccessorSetter):
1593         (WebCore::V8Location::reloadAccessorGetter):
1594         (WebCore::V8Location::replaceAccessorGetter):
1595         (WebCore::V8Location::assignAccessorGetter):
1596         (WebCore::V8Location::reloadCallback):
1597         (WebCore::V8Location::replaceCallback):
1598         (WebCore::V8Location::assignCallback):
1599         (WebCore::V8Location::toStringCallback):
1600         (WebCore::V8Location::indexedSecurityCheck):
1601         (WebCore::V8Location::namedSecurityCheck):
1602         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
1603         * bindings/v8/custom/V8NodeCustom.cpp:
1604
1605 2012-08-02  Abhishek Arya  <inferno@chromium.org>
1606
1607         No isChildAllowed checked when adding RenderFullScreen as the child..
1608         https://bugs.webkit.org/show_bug.cgi?id=92995
1609
1610         Reviewed by Eric Seidel.
1611
1612         Test: fullscreen/fullscreen-child-not-allowed-crash.html
1613
1614         * dom/Document.cpp:
1615         (WebCore::Document::webkitWillEnterFullScreenForElement): pass the object's parent
1616         pointer as an additional argument.
1617         * dom/NodeRenderingContext.cpp:
1618         (WebCore::NodeRendererFactory::createRendererIfNeeded): pass the to be parent |parentRenderer|
1619         as the argument. 
1620         * rendering/RenderFullScreen.cpp:
1621         (RenderFullScreen::wrapRenderer): make sure that parent allows RenderFullScreen as the child.
1622         * rendering/RenderFullScreen.h: 
1623         (RenderFullScreen): support the object's parent
1624         pointer as an additional argument.
1625
1626 2012-08-01  James Robinson  <jamesr@chromium.org>
1627
1628         [chromium] Wrap shared context getters in WebKit API and avoid WebCore::GraphicsContext3D use in compositor internals
1629         https://bugs.webkit.org/show_bug.cgi?id=92917
1630
1631         Reviewed by Adrienne Walker.
1632
1633         This uses Platform API wrappers to access the shared WebGraphicsContext3D / Ganesh contexts from the compositor
1634         to evaluate accelerated filters or do accelerated painting.
1635
1636         Filters changes covered by css3/filters/*-hw.html layout tests.
1637
1638         * WebCore.gypi:
1639         * platform/chromium/support/WebSharedGraphicsContext3D.cpp:
1640         (WebKit):
1641         (WebKit::WebSharedGraphicsContext3D::mainThreadContext):
1642         (WebKit::WebSharedGraphicsContext3D::mainThreadGrContext):
1643         (WebKit::WebSharedGraphicsContext3D::compositorThreadContext):
1644         (WebKit::WebSharedGraphicsContext3D::compositorThreadGrContext):
1645         (WebKit::WebSharedGraphicsContext3D::haveCompositorThreadContext):
1646         (WebKit::WebSharedGraphicsContext3D::createCompositorThreadContext):
1647         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.cpp:
1648         (WebCore::createAcceleratedCanvas):
1649         (WebCore::FrameBufferSkPictureCanvasLayerTextureUpdater::Texture::updateRect):
1650         (WebCore::FrameBufferSkPictureCanvasLayerTextureUpdater::updateTextureRect):
1651         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.h:
1652         (WebKit):
1653         (FrameBufferSkPictureCanvasLayerTextureUpdater):
1654         * platform/graphics/chromium/LayerRendererChromium.cpp:
1655         (WebCore::applyFilters):
1656         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
1657         (WebCore::CCRenderSurfaceFilters::apply):
1658         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.h:
1659         (WebKit):
1660         (CCRenderSurfaceFilters):
1661
1662 2012-08-02  Beth Dakin  <bdakin@apple.com>
1663
1664         https://bugs.webkit.org/show_bug.cgi?id=93020
1665         REGRESSION (tiled scrolling): Full-screen video is broken if page is 
1666         scrolled
1667         -and corresponding-
1668         <rdar://problem/11629778>
1669
1670         Reviewed by Anders Carlsson.
1671
1672         The bug here is that ScrollingTreeNodeMac::setScrollLayerPosition() 
1673         uses the CALayer (PlatformLayer) directly to set the position. That 
1674         means that the GraphicsLayer that owns that PlatformLayer does not 
1675         have updated position information. That results in this bug when we 
1676         switch from fast scrolling to main thread scrolling, because at that 
1677         point, the GraphicsLayer needs to have the correct information. So 
1678         make sure to update the main thread scroll position and layer 
1679         position before transitioning to main thread scrolling.
1680         * page/scrolling/ScrollingCoordinator.cpp:
1681         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
1682
1683 2012-08-02  Addy Osmani  <addyo@chromium.org>
1684
1685         Web Inspector: Rename 'User agent' to 'Overrides' in settings screen
1686         https://bugs.webkit.org/show_bug.cgi?id=92990
1687
1688         Reviewed by Pavel Feldman.
1689
1690         Simple setting rename of User agent -> Overrides
1691
1692         * English.lproj/localizedStrings.js:
1693         * inspector/front-end/SettingsScreen.js:
1694
1695 2012-08-02  Philip Rogers  <pdr@google.com>
1696
1697         Do not dispatch modification events in SVG attribute synchronization
1698         https://bugs.webkit.org/show_bug.cgi?id=92604
1699
1700         Reviewed by Ryosuke Niwa.
1701
1702         Previously, calling hasAttribute() during layout could hit a
1703         layout-during-layout bug because calling hasAttribute() could dispatch a 
1704         subtree modification event which could synchronously force a layout. hasAttribute()
1705         exhibits this behavior because property synchronization is done lazily.
1706
1707         This patch skips dispatching subtree modification events during attribute
1708         synchronization.
1709
1710         Additionally, this patch contains a refactoring of lazy attribute setting. We
1711         now have a single place where lazy attributes are set (setSynchronizedLazyAttribute)
1712         and lazy attribute flags have been moved to just Element and ElementAttributeData.
1713
1714         Test: svg/custom/path-domsubtreemodified-crash.html
1715
1716         * dom/Element.cpp:
1717         (WebCore::Element::setAttribute):
1718         (WebCore::Element::setSynchronizedLazyAttribute):
1719         (WebCore):
1720         (WebCore::Element::setAttributeInternal):
1721         * dom/Element.h:
1722         (Element):
1723         * dom/ElementAttributeData.cpp:
1724         (WebCore::ElementAttributeData::addAttribute):
1725         (WebCore::ElementAttributeData::removeAttribute):
1726         * dom/ElementAttributeData.h:
1727         (ElementAttributeData):
1728         * dom/StyledElement.cpp:
1729         (WebCore::StyledElement::updateStyleAttribute):
1730         * svg/properties/SVGAnimatedPropertyMacros.h:
1731         (WebCore::SVGSynchronizableAnimatedProperty::synchronize):
1732
1733 2012-08-02  Konrad Piascik  <kpiascik@rim.com>
1734
1735         Web Inspector: Override the DeviceOrientation
1736         https://bugs.webkit.org/show_bug.cgi?id=91008
1737
1738         Reviewed by Pavel Feldman.
1739
1740         Re-added the m_page member variable to DeviceOrientationController and
1741         added InspectorInstrumentation to see if the DeviceOrientationData
1742         should be overridden or not.
1743
1744         Added UI to the web inspector front-end to allow users to override the
1745         device orientation.  This is currently hidden behind an experiment.
1746
1747         Test: inspector/device-orientation-success.html
1748
1749         * English.lproj/localizedStrings.js:
1750         * dom/DeviceOrientationController.cpp:
1751         (WebCore::DeviceOrientationController::DeviceOrientationController):
1752         (WebCore::DeviceOrientationController::create):
1753         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
1754         (WebCore::provideDeviceOrientationTo):
1755         * dom/DeviceOrientationController.h:
1756         (DeviceOrientationController):
1757         * inspector/Inspector.json:
1758         * inspector/InspectorInstrumentation.cpp:
1759         (WebCore):
1760         (WebCore::InspectorInstrumentation::overrideDeviceOrientationImpl):
1761         * inspector/InspectorInstrumentation.h:
1762         (WebCore):
1763         (InspectorInstrumentation):
1764         (WebCore::InspectorInstrumentation::overrideDeviceOrientation):
1765         * inspector/InspectorPageAgent.cpp:
1766         (WebCore::InspectorPageAgent::setDeviceOrientationOverride):
1767         (WebCore):
1768         (WebCore::InspectorPageAgent::clearDeviceOrientationOverride):
1769         (WebCore::InspectorPageAgent::canOverrideDeviceOrientation):
1770         (WebCore::InspectorPageAgent::overrideDeviceOrientation):
1771         * inspector/InspectorPageAgent.h:
1772         * inspector/front-end/Settings.js:
1773         (WebInspector.ExperimentsSettings):
1774         * inspector/front-end/SettingsScreen.js:
1775         (WebInspector.UserAgentSettingsTab):
1776         (WebInspector.UserAgentSettingsTab.prototype._createInput):
1777         (WebInspector.UserAgentSettingsTab.prototype._createDeviceMetricsElement):
1778         (WebInspector.UserAgentSettingsTab.prototype._createGeolocationOverrideElement):
1779         (WebInspector.UserAgentSettingsTab.prototype._onDeviceOrientationOverrideCheckboxClicked):
1780         (WebInspector.UserAgentSettingsTab.prototype._applyDeviceOrientationUserInput):
1781         (WebInspector.UserAgentSettingsTab.prototype._setDeviceOrientation.set if):
1782         (WebInspector.UserAgentSettingsTab.prototype._setDeviceOrientation):
1783         (WebInspector.UserAgentSettingsTab.prototype._createDeviceOrientationOverrideElement):
1784         * inspector/front-end/UserAgentSupport.js:
1785         (WebInspector.UserAgentSupport.DeviceOrientation):
1786         (WebInspector.UserAgentSupport.DeviceOrientation.prototype.toSetting):
1787         (WebInspector.UserAgentSupport.DeviceOrientation.parseSetting):
1788         (WebInspector.UserAgentSupport.DeviceOrientation.parseUserInput):
1789         (WebInspector.UserAgentSupport.DeviceOrientation.clearDeviceOrientationOverride):
1790         * inspector/front-end/inspector.js:
1791         (WebInspector.doLoadedDone):
1792
1793 2012-08-02  Arnaud Renevier  <a.renevier@sisa.samsung.com>
1794
1795         TypedArray set method is slow when called with another typed array
1796         https://bugs.webkit.org/show_bug.cgi?id=92556
1797
1798         Reviewed by Kenneth Russell.
1799
1800         When setting multiples values to a typed array from an array like
1801         element, try to determine if the argument is a typed array. If so,
1802         cast the argument to a typed array, and read each element with .item()
1803         method. That avoid reading the value as a JSValue, and speedups set
1804         method by approximatively 10x.
1805
1806         Introduce setWebGLArrayWithTypedArrayArgument template function which
1807         checks if argument is a typed array. If so, it copies the data to
1808         target typed array and returns true. Otherwise, it returns false.
1809
1810         Introduce copyTypedArrayBuffer template function which copies data
1811         from a typed array to another one. This function is also used from
1812         constructArrayBufferViewWithTypedArrayArgument.
1813
1814         * bindings/js/JSArrayBufferViewHelper.h:
1815         (WebCore):
1816         (WebCore::copyTypedArrayBuffer):
1817         (WebCore::setWebGLArrayWithTypedArrayArgument):
1818         (WebCore::setWebGLArrayHelper):
1819         (WebCore::constructArrayBufferViewWithTypedArrayArgument):
1820         * bindings/js/JSFloat32ArrayCustom.cpp:
1821         (WebCore::JSFloat32Array::set):
1822         * bindings/js/JSFloat64ArrayCustom.cpp:
1823         (WebCore::JSFloat64Array::set):
1824         * bindings/js/JSInt16ArrayCustom.cpp:
1825         (WebCore::JSInt16Array::set):
1826         * bindings/js/JSInt32ArrayCustom.cpp:
1827         (WebCore::JSInt32Array::set):
1828         * bindings/js/JSInt8ArrayCustom.cpp:
1829         (WebCore::JSInt8Array::set):
1830         * bindings/js/JSUint16ArrayCustom.cpp:
1831         (WebCore::JSUint16Array::set):
1832         * bindings/js/JSUint32ArrayCustom.cpp:
1833         (WebCore::JSUint32Array::set):
1834         * bindings/js/JSUint8ArrayCustom.cpp:
1835         (WebCore::JSUint8Array::set):
1836         * bindings/js/JSUint8ClampedArrayCustom.cpp:
1837         (WebCore::JSUint8ClampedArray::set):
1838
1839 2012-08-02  Chris Fleizach  <cfleizach@apple.com>
1840
1841         AXEnabled = false for AXIncrementors inside text fields
1842         https://bugs.webkit.org/show_bug.cgi?id=93008
1843
1844         Reviewed by Anders Carlsson.
1845
1846         Mock objects should return "enabled" by default, since they are valid objects.
1847
1848         * accessibility/AccessibilityMockObject.h:
1849         (WebCore::AccessibilityMockObject::isEnabled):
1850         (AccessibilityMockObject):
1851
1852 2012-08-02  Eric Seidel  <eric@webkit.org>
1853
1854         Add back ASSERT(!needsLayout) to RenderTableSection which is now valid
1855         https://bugs.webkit.org/show_bug.cgi?id=92954
1856
1857         Reviewed by Julien Chaffraix.
1858
1859         * rendering/RenderTableSection.cpp:
1860         (WebCore::RenderTableSection::paint):
1861
1862 2012-08-02  Kevin Ellis  <kevers@chromium.org>
1863
1864         Month-year selector on calendar picker should be touch friendly.
1865         https://bugs.webkit.org/show_bug.cgi?id=92678
1866
1867         Reviewed by Kent Tamura.
1868
1869         Previously the month-year popup menu was implemented using a listbox,
1870         which does not support CSS customization.  Entries in the listbox
1871         were too shallow to reliably target with touch gestures.  The
1872         replacement popup is CSS configurable with larger entries on devices
1873         that support touch input.
1874
1875         Manually tested with and without touch support in English, Japanese
1876         and Arabic.
1877
1878         * Resources/calendarPicker.css:
1879         (.month-selector-popup): Update to use scrollable div instead of listbox.
1880         (.month-selector-popup-contents): Render popup as a table within a scrollable div.
1881         (.month-selector-popup-entry): Formatting entries in the month-year popup.
1882         (.selected-month-year): Highlight the selected month-year.
1883         (@media (pointer:coarse)): Enlarge entries in the popup meu on devices that support touch.
1884         * Resources/calendarPicker.js:
1885         (YearMonthController.prototype.attachTo): Change selector popup from a list-box to a div.
1886         (YearMonthController.prototype._redraw): Populate table based popup rather than listbox.
1887         (YearMonthController.prototype._showPopup): Set scroll position and resize for scrollbar.
1888         (YearMonthController.prototype._closePopup): Restore focus to the calendar.
1889         (YearMonthController.prototype._getSelection): Added to retrieve the selected month-year.
1890         (YearMonthController.prototype._handleMouseMove): Added to update selected month-year on hover.
1891         (YearMonthController.prototype._handleMonthPopupKey): Add keyboard navigation.
1892         (YearMonthController.prototype._handleYearMonthChange): Retrieve value from selected month-year.
1893
1894 2012-08-02  Vsevolod Vlasov  <vsevik@chromium.org>
1895
1896         Web Inspector: [Regression] context menu does not open on Sources panel tabs on mac
1897         https://bugs.webkit.org/show_bug.cgi?id=93000
1898
1899         Reviewed by Pavel Feldman.
1900
1901         * inspector/front-end/UIUtils.js:
1902         (WebInspector._elementDragStart):
1903
1904 2012-08-02  Kwang Yul Seo  <skyul@company100.net>
1905
1906         Check if the last table element's parent node is an element when determining the foster parent element.
1907         https://bugs.webkit.org/show_bug.cgi?id=92977
1908
1909         Reviewed by Adam Barth.
1910
1911         According to the HTML5 spec, if the last table element in the stack of open elements has no parent,
1912         or ITS PARENT NODE IS NOT AN ELEMENT, then the foster parent element is the element
1913         before the last table element in the stack of open elements.
1914
1915         Changed to check if the table element's parent node is an element.
1916
1917         Test: fast/parser/foster-parent.html
1918
1919         * html/parser/HTMLConstructionSite.cpp:
1920         (WebCore::HTMLConstructionSite::findFosterSite):
1921
1922 2012-08-02  Philippe Normand  <pnormand@igalia.com>
1923
1924         [GStreamer] Use GST_DEBUG instead of LOG_VERBOSE
1925         https://bugs.webkit.org/show_bug.cgi?id=89350
1926
1927         Reviewed by Martin Robinson.
1928
1929         Wrap the media player's logging calls to a new macro that also
1930         hooks into GStreamer's logging facilities. This way the developer
1931         gets the best of both worlds, leaving the choice between GST_DEBUG
1932         and WEBKIT_DEBUG environment variables.
1933
1934         * platform/graphics/gstreamer/GStreamerUtilities.h:
1935         (WebCore):
1936         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1937         (WebCore::initializeGStreamerAndRegisterWebKitElements):
1938         (WebCore::MediaPlayerPrivateGStreamer::load):
1939         (WebCore::MediaPlayerPrivateGStreamer::commitLoad):
1940         (WebCore::MediaPlayerPrivateGStreamer::playbackPosition):
1941         (WebCore::MediaPlayerPrivateGStreamer::play):
1942         (WebCore::MediaPlayerPrivateGStreamer::pause):
1943         (WebCore::MediaPlayerPrivateGStreamer::duration):
1944         (WebCore::MediaPlayerPrivateGStreamer::seek):
1945         (WebCore::MediaPlayerPrivateGStreamer::naturalSize):
1946         (WebCore::MediaPlayerPrivateGStreamer::setRate):
1947         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
1948         (WebCore::MediaPlayerPrivateGStreamer::processBufferingStats):
1949         (WebCore::MediaPlayerPrivateGStreamer::fillTimerFired):
1950         (WebCore::MediaPlayerPrivateGStreamer::maxTimeSeekable):
1951         (WebCore::MediaPlayerPrivateGStreamer::maxTimeLoaded):
1952         (WebCore::MediaPlayerPrivateGStreamer::didLoadingProgress):
1953
1954 2012-08-02  Antti Koivisto  <antti@apple.com>
1955
1956         Inline stylesheets can confuse style sharing
1957         https://bugs.webkit.org/show_bug.cgi?id=92970
1958
1959         Reviewed by Dan Bernstein.
1960
1961         Consider document 
1962         
1963         <div class="i30"></div>
1964         <style>.i30 { background-color:green; }</style>
1965         <div class="i30"></div>
1966         
1967         When processing the <style> element the scope optimization marks the first div as needing style recalc. 
1968         Next the parser adds the second div to the tree and immediately calculates its style. Since it looks exactly 
1969         like the first div the style sharing optimization copies the style from there. The pending recalc of the
1970         first div is resolved by a timer but the second div is left with the old style.
1971         
1972         Fix by disallowing style sharing from elements with pending style recalc.
1973
1974         Test: fast/css/style-sharing-inline-stylesheet.html
1975
1976         * css/StyleResolver.cpp:
1977         (WebCore::StyleResolver::canShareStyleWithElement):
1978
1979 2012-08-02  Tommy Widenflycht  <tommyw@google.com>
1980
1981         MediaStream API: Add RTCPeerConnectionHandler infrastructure
1982         https://bugs.webkit.org/show_bug.cgi?id=92866
1983
1984         Reviewed by Adam Barth.
1985
1986         Introducing RTCPeerConnectionHandler & RTCPeerConnectionHandlerClient,
1987         together with the Chromium WebKit interface, following the pattern of
1988         the previous PeerConnection00Handler but with the optimizations from MediaStreamCenter.
1989
1990         Not yet testable due to not enough code landed.
1991
1992         * CMakeLists.txt:
1993         * GNUmakefile.list.am:
1994         * Modules/mediastream/RTCPeerConnection.cpp:
1995         (WebCore::RTCPeerConnection::create):
1996         (WebCore::RTCPeerConnection::RTCPeerConnection):
1997         * Modules/mediastream/RTCPeerConnection.h:
1998         (RTCPeerConnection):
1999         * WebCore.gypi:
2000         * platform/mediastream/RTCPeerConnectionHandler.cpp: Added.
2001         (WebCore):
2002         (RTCPeerConnectionHandlerDummy):
2003         (WebCore::RTCPeerConnectionHandler::create):
2004         (WebCore::RTCPeerConnectionHandlerDummy::RTCPeerConnectionHandlerDummy):
2005         (WebCore::RTCPeerConnectionHandlerDummy::~RTCPeerConnectionHandlerDummy):
2006         (WebCore::RTCPeerConnectionHandlerDummy::initialize):
2007         * platform/mediastream/RTCPeerConnectionHandler.h: Copied from Source/WebCore/Modules/mediastream/RTCPeerConnection.h.
2008         (WebCore):
2009         (RTCPeerConnectionHandler):
2010         (WebCore::RTCPeerConnectionHandler::~RTCPeerConnectionHandler):
2011         (WebCore::RTCPeerConnectionHandler::RTCPeerConnectionHandler):
2012         * platform/mediastream/RTCPeerConnectionHandlerClient.h: Copied from Source/WebCore/Modules/mediastream/RTCPeerConnection.h.
2013         (WebCore):
2014         (RTCPeerConnectionHandlerClient):
2015         (WebCore::RTCPeerConnectionHandlerClient::~RTCPeerConnectionHandlerClient):
2016         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp: Added.
2017         (WebCore):
2018         (WebCore::RTCPeerConnectionHandler::create):
2019         (WebCore::RTCPeerConnectionHandlerChromium::RTCPeerConnectionHandlerChromium):
2020         (WebCore::RTCPeerConnectionHandlerChromium::~RTCPeerConnectionHandlerChromium):
2021         (WebCore::RTCPeerConnectionHandlerChromium::initialize):
2022         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h: Added.
2023         (WebCore):
2024         (RTCPeerConnectionHandlerChromium):
2025
2026 2012-08-02  Kent Tamura  <tkent@chromium.org>
2027
2028         Move number localization code in LocaleICU.cpp to new class
2029         https://bugs.webkit.org/show_bug.cgi?id=92976
2030
2031         Reviewed by Kentaro Hara.
2032
2033         The number localization code by character mapping is usefull for non-ICU
2034         platforms.
2035
2036         No new tests. This is just a refactoring, and is covered by
2037         Source/WebKit/chromium/tests/LocalizedNumberICUTest.cpp.
2038
2039         * WebCore.gypi: Add NumberLocalizer.{cpp,h}.
2040         * platform/text/LocaleICU.cpp:
2041         (WebCore::LocaleICU::decimalSymbol):
2042         Renamed from setDecimalSymbol. This function returns the resultant
2043         string instead of setting it to a data member.
2044         (WebCore::LocaleICU::decimalTextAttribute):
2045         Renamed from setDecimalTextAttributel. This function returns the
2046         resultant string instead of setting it to the specified string.
2047         (WebCore::LocaleICU::initializeNumberLocalizerData):
2048         Renamed from initializeDecimalFormat.
2049         Calls NumberLocaizer::setNumberLocalizerData.
2050         (WebCore::LocaleICU::localizedDecimalSeparator):
2051         Rename initializeDecimalFormat to initializeNumberLocalizerData.
2052         * platform/text/LocaleICU.h:
2053         (LocaleICU): Remove some members, and inherit NumberLocalizer.
2054         * platform/text/NumberLocalizer.cpp: Added. Move the code from LocaleICU.cpp
2055         (WebCore):
2056         (WebCore::NumberLocalizer::~NumberLocalizer):
2057         (WebCore::NumberLocalizer::setNumberLocalizerData): Added.
2058         (WebCore::NumberLocalizer::convertToLocalizedNumber):
2059         (WebCore::matches):
2060         (WebCore::NumberLocalizer::detectSignAndGetDigitRange):
2061         (WebCore::NumberLocalizer::matchedDecimalSymbolIndex):
2062         (WebCore::NumberLocalizer::convertFromLocalizedNumber):
2063         (WebCore::NumberLocalizer::localizedDecimalSeparator):
2064         * platform/text/NumberLocalizer.h: Added.
2065         (NumberLocalizer):
2066         (WebCore::NumberLocalizer::NumberLocalizer):
2067
2068 2012-08-02  Alexander Pavlov  <apavlov@chromium.org>
2069
2070         Web Inspector: Move DOM breakpoints-related context menu items into a submenu
2071         https://bugs.webkit.org/show_bug.cgi?id=92989
2072
2073         Reviewed by Vsevolod Vlasov.
2074
2075         A "Break on..." submenu is added to the element context menu, to host all DOM breakpoint items.
2076
2077         * English.lproj/localizedStrings.js:
2078         * inspector/front-end/DOMBreakpointsSidebarPane.js:
2079         (WebInspector.DOMBreakpointsSidebarPane):
2080         (WebInspector.DOMBreakpointsSidebarPane.prototype.populateNodeContextMenu):
2081
2082 2012-08-02  Dominik Röttsches  <dominik.rottsches@intel.com>
2083
2084         [Cairo] Add complex font drawing using HarfbuzzNG
2085         https://bugs.webkit.org/show_bug.cgi?id=91864
2086
2087         Reviewed by Martin Robinson.
2088
2089         Unfortunately the Freetype based approach that avoids allocations and UTF8 conversion
2090         fails to produce correct results for some tests.
2091
2092         No new tests, at least
2093           fast/dom/52776.html
2094           fast/text/atsui-negative-spacing-features.html
2095           fast/text/atsui-spacing-features.html
2096         expose this problem.
2097
2098         * platform/graphics/harfbuzz/ng/HarfBuzzNGFaceCairo.cpp:
2099         (WebCore::harfbuzzGetGlyph): Revert to initial cairo_scaled_font based approach.
2100
2101 2012-08-02  Eugene Klyuchnikov  <eustas.big@gmail.com>
2102
2103         Web Inspector: Fix protocol version check.
2104         https://bugs.webkit.org/show_bug.cgi?id=91497
2105
2106         Reviewed by Pavel Feldman.
2107
2108         Generated method 'supportsInspectorProtocolVersion' should return
2109         false when requested  minor version is *greater* than actual
2110         minor version.
2111
2112         * inspector/generate-inspector-protocol-version: Fixed stub text
2113
2114 2012-08-02  Alexei Filippov  <alexeif@chromium.org>
2115
2116         Web Inspector: count RenderStyle objects in the native memory profiler
2117         https://bugs.webkit.org/show_bug.cgi?id=91759
2118
2119         Reviewed by Yury Semikhatsky.
2120
2121         The patch adds instrumentation to the following classes:
2122           - RenderStyle
2123           - StyleRareInheritedData
2124           - StyleRareNonInheritedData
2125
2126         * bindings/js/ScriptWrappable.h:
2127         * bindings/v8/ScriptWrappable.h:
2128         * dom/MemoryInstrumentation.h:
2129         (WebCore):
2130         (WebCore::MemoryInstrumentation::OwningTraits::addObject):
2131         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
2132         (WebCore::MemoryInstrumentation::addObjectImpl):
2133         * dom/Node.cpp:
2134         (WebCore::Node::reportMemoryUsage):
2135         * dom/Node.h:
2136         (WebCore):
2137         * rendering/style/RenderStyle.cpp:
2138         (WebCore::RenderStyle::reportMemoryUsage):
2139         (WebCore):
2140         * rendering/style/RenderStyle.h:
2141         (WebCore):
2142         * rendering/style/StyleRareInheritedData.cpp:
2143         (WebCore::StyleRareInheritedData::reportMemoryUsage):
2144         (WebCore):
2145         * rendering/style/StyleRareInheritedData.h:
2146         (WebCore):
2147         (StyleRareInheritedData):
2148         * rendering/style/StyleRareNonInheritedData.cpp:
2149         (WebCore::StyleRareNonInheritedData::reportMemoryUsage):
2150         (WebCore):
2151         * rendering/style/StyleRareNonInheritedData.h:
2152         (WebCore):
2153         (StyleRareNonInheritedData):
2154
2155 2012-08-02  Alexei Filippov  <alexeif@chromium.org>
2156
2157         Web Inspector: rename host->origin in the inspector protocol DOMStorage entry
2158         https://bugs.webkit.org/show_bug.cgi?id=92979
2159
2160         Reviewed by Yury Semikhatsky.
2161
2162         * inspector/Inspector.json:
2163         * inspector/InspectorDOMStorageResource.cpp:
2164         (WebCore::InspectorDOMStorageResource::bind):
2165         * inspector/front-end/DOMStorage.js:
2166         (WebInspector.DOMStorageDispatcher.prototype.addDOMStorage):
2167
2168 2012-08-02  Kihong Kwon  <kihong.kwon@samsung.com>
2169
2170         [EFL] Change return value of battey level
2171         https://bugs.webkit.org/show_bug.cgi?id=92964
2172
2173         Reviewed by Simon Hausmann.
2174
2175         Change return value of navigator.webkitBattery.level from 0~100 to 0~1.0.
2176         Battery level have to returns 0~1.0 by Battery Status API spec.
2177
2178         * platform/efl/BatteryProviderEfl.cpp:
2179         (WebCore::BatteryProviderEfl::setBatteryClient):
2180
2181 2012-08-02  Yury Semikhatsky  <yurys@chromium.org>
2182
2183         Web Inspector: remove extraObjectSize parameter from MemoryClassInfo constructor
2184         https://bugs.webkit.org/show_bug.cgi?id=92981
2185
2186         Reviewed by Alexander Pavlov.
2187
2188         Refactored MemoryInstrumentation to get rid of extraSize parameter from
2189         MemoryObjectInfo constructor and MemoryObjectInfo::reportObjectInfo. The
2190         extra size should always be reported as an object that occupies these extra
2191         bytes.
2192
2193         * dom/ElementAttributeData.cpp:
2194         (WebCore::ElementAttributeData::reportMemoryUsage):
2195         (WebCore):
2196         * dom/ElementAttributeData.h:
2197         (WebCore):
2198         (ElementAttributeData):
2199         * dom/MemoryInstrumentation.h:
2200         (WebCore::MemoryObjectInfo::reportObjectInfo):
2201         (WebCore::MemoryClassInfo::MemoryClassInfo):
2202
2203 2012-08-02  Sheriff Bot  <webkit.review.bot@gmail.com>
2204
2205         Unreviewed, rolling out r124439.
2206         http://trac.webkit.org/changeset/124439
2207         https://bugs.webkit.org/show_bug.cgi?id=92980
2208
2209         Broke Chromium Mac Release compile (Requested by apavlov on
2210         #webkit).
2211
2212         * CMakeLists.txt:
2213         * GNUmakefile.list.am:
2214         * Modules/mediastream/RTCPeerConnection.cpp:
2215         (WebCore::RTCPeerConnection::create):
2216         (WebCore::RTCPeerConnection::RTCPeerConnection):
2217         * Modules/mediastream/RTCPeerConnection.h:
2218         * WebCore.gypi:
2219         * platform/mediastream/RTCPeerConnectionHandler.cpp: Removed.
2220         * platform/mediastream/RTCPeerConnectionHandler.h: Removed.
2221         * platform/mediastream/RTCPeerConnectionHandlerClient.h: Removed.
2222         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp: Removed.
2223         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h: Removed.
2224
2225 2012-08-02  Simon Hausmann  <simon.hausmann@nokia.com>
2226
2227         [Qt] Uninitialized memory read in QObject runtime bridge
2228         https://bugs.webkit.org/show_bug.cgi?id=92972
2229
2230         Reviewed by Kenneth Rohde Christiansen.
2231
2232         The vargs array has an initial size of 0 and when calling a method with no return value
2233         and no arguments, vargs remains empty. Therefore unconditional access to vargs[0] results
2234         in access to uninitialized memory.
2235
2236         No new tests, covered by valgrind in existing qobjectbridge tests.
2237
2238         * bridge/qt/qt_runtime.cpp:
2239         (JSC::Bindings::QtRuntimeMetaMethod::call):
2240         * bridge/qt/qt_runtime_qt4.cpp:
2241         (JSC::Bindings::QtRuntimeMetaMethod::call):
2242
2243 2012-08-02  Zoltan Herczeg  <zherczeg@webkit.org>
2244
2245         Alignment issue for readTime in PluginDatabase.cpp
2246         https://bugs.webkit.org/show_bug.cgi?id=92746
2247
2248         Reviewed by Simon Hausmann.
2249
2250         When the byte stream is written, nothing guarantees that
2251         the time_t data is aligned. This issue caused alignment
2252         traps on ARM CPUs.
2253
2254         No new tests. Covered by existing tests.
2255
2256         * plugins/PluginDatabase.cpp:
2257         (WebCore::readTime):
2258
2259 2012-08-02  Tommy Widenflycht  <tommyw@google.com>
2260
2261         MediaStream API: Add RTCPeerConnectionHandler infrastructure
2262         https://bugs.webkit.org/show_bug.cgi?id=92866
2263
2264         Reviewed by Kentaro Hara.
2265
2266         Introducing RTCPeerConnectionHandler & RTCPeerConnectionHandlerClient,
2267         together with the Chromium WebKit interface, following the pattern of
2268         the previous PeerConnection00Handler but with the optimizations from MediaStreamCenter.
2269
2270         Not yet testable due to not enough code landed.
2271
2272         * CMakeLists.txt:
2273         * GNUmakefile.list.am:
2274         * Modules/mediastream/RTCPeerConnection.cpp:
2275         (WebCore::RTCPeerConnection::create):
2276         (WebCore::RTCPeerConnection::RTCPeerConnection):
2277         * Modules/mediastream/RTCPeerConnection.h:
2278         (RTCPeerConnection):
2279         * WebCore.gypi:
2280         * platform/mediastream/RTCPeerConnectionHandler.cpp: Added.
2281         (WebCore):
2282         (RTCPeerConnectionHandlerDummy):
2283         (WebCore::RTCPeerConnectionHandler::create):
2284         (WebCore::RTCPeerConnectionHandlerDummy::RTCPeerConnectionHandlerDummy):
2285         (WebCore::RTCPeerConnectionHandlerDummy::~RTCPeerConnectionHandlerDummy):
2286         (WebCore::RTCPeerConnectionHandlerDummy::initialize):
2287         * platform/mediastream/RTCPeerConnectionHandler.h: Copied from Source/WebCore/Modules/mediastream/RTCPeerConnection.h.
2288         (WebCore):
2289         (RTCPeerConnectionHandler):
2290         (WebCore::RTCPeerConnectionHandler::~RTCPeerConnectionHandler):
2291         (WebCore::RTCPeerConnectionHandler::RTCPeerConnectionHandler):
2292         * platform/mediastream/RTCPeerConnectionHandlerClient.h: Copied from Source/WebCore/Modules/mediastream/RTCPeerConnection.h.
2293         (WebCore):
2294         (RTCPeerConnectionHandlerClient):
2295         (WebCore::RTCPeerConnectionHandlerClient::~RTCPeerConnectionHandlerClient):
2296         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp: Added.
2297         (WebCore):
2298         (WebCore::RTCPeerConnectionHandler::create):
2299         (WebCore::RTCPeerConnectionHandlerChromium::RTCPeerConnectionHandlerChromium):
2300         (WebCore::RTCPeerConnectionHandlerChromium::~RTCPeerConnectionHandlerChromium):
2301         (WebCore::RTCPeerConnectionHandlerChromium::initialize):
2302         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h: Added.
2303         (WebCore):
2304         (RTCPeerConnectionHandlerChromium):
2305
2306 2012-08-02  Yury Semikhatsky  <yurys@chromium.org>
2307
2308         Web Inspector: rename reportMemoryUsage to reportDescendantMemoryUsage in StyleRuleBase descendants
2309         https://bugs.webkit.org/show_bug.cgi?id=92966
2310
2311         Reviewed by Alexander Pavlov.
2312
2313         Renamed reportMemoryUsage to reportDescendantMemoryUsage in all descendants of
2314         StyleRuleBase to avoid accidental recursive calls to StyleRuleBase::reportMemoryUsage
2315         when a new type of rule is added.
2316
2317         * css/StyleRule.cpp:
2318         (WebCore::StyleRuleBase::reportMemoryUsage):
2319         (WebCore::StyleRule::reportDescendantMemoryUsage):
2320         (WebCore::StyleRulePage::reportDescendantMemoryUsage):
2321         (WebCore::StyleRuleFontFace::reportDescendantMemoryUsage):
2322         (WebCore::StyleRuleBlock::reportDescendantMemoryUsage):
2323         (WebCore::StyleRuleMedia::reportDescendantMemoryUsage):
2324         (WebCore::StyleRuleRegion::reportDescendantMemoryUsage):
2325         * css/StyleRule.h:
2326         (StyleRule):
2327         (StyleRuleFontFace):
2328         (StyleRulePage):
2329         (StyleRuleBlock):
2330         (StyleRuleMedia):
2331         (StyleRuleRegion):
2332         * css/StyleRuleImport.cpp:
2333         (WebCore::StyleRuleImport::reportDescendantMemoryUsage):
2334         * css/StyleRuleImport.h:
2335         (StyleRuleImport):
2336         * css/WebKitCSSKeyframesRule.cpp:
2337         (WebCore::StyleRuleKeyframes::reportDescendantMemoryUsage):
2338         * css/WebKitCSSKeyframesRule.h:
2339         (StyleRuleKeyframes):
2340
2341 2012-08-02  Hironori Bono  <hbono@chromium.org>
2342
2343         [Chromium] Implement hyphenation for Chromium
2344         https://bugs.webkit.org/show_bug.cgi?id=48610
2345
2346         Reviewed by Eric Seidel.
2347
2348         This change adds a couple of methods canHyphenate and computeLastHyphenLocation
2349         to Platform so Chromium can implement them. Also, this change uses these methods
2350         to implement the hyphenation methods of WebCore. (This change does not change
2351         any behaviors until Chromium implements these methods.)
2352
2353         No new tests because this change is for fixing a couple of existing layout tests
2354         'fast/text/hyphenate-character.html' and 'fast/text/hyphens.html'.
2355
2356         * WebCore.gypi:
2357         * platform/text/chromium/Hyphenation.cpp: Added.
2358         (WebCore):
2359         (WebCore::canHyphenate): Called Platform::canHyphenation().
2360         (WebCore::lastHyphenLocation): Called Platform::computeLastHyphenLocation().
2361
2362 2012-08-02  ulan@chromium.org  <ulan@chromium.org>
2363
2364         [chromium] Improve garbage collector hint if page uses Canvas contexts
2365         https://bugs.webkit.org/show_bug.cgi?id=92856
2366
2367         Reviewed by Kentaro Hara.
2368
2369         Request GC by sending context disposed and idle notification to V8 instead
2370         of sending low memory notification. It is faster as it causes one GC
2371         instead of seven GCs caused by low memory notification.
2372
2373         * bindings/v8/V8Binding.cpp:
2374         (WebCore::V8BindingPerIsolateData::V8BindingPerIsolateData):
2375         * bindings/v8/V8Binding.h:
2376         (V8BindingPerIsolateData):
2377         (WebCore::V8BindingPerIsolateData::setShouldCollectGarbageSoon):
2378         (WebCore::V8BindingPerIsolateData::clearShouldCollectGarbageSoon):
2379         (WebCore::V8BindingPerIsolateData::shouldCollectGarbageSoon):
2380         * bindings/v8/V8Proxy.cpp:
2381         (WebCore::V8Proxy::hintForGCIfNecessary):
2382         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
2383         (WebCore::V8HTMLCanvasElement::getContextCallback):
2384
2385 2012-08-02  Mihnea Ovidenie  <mihnea@adobe.com>
2386
2387         CSSRegions: Crash when reattaching a region to a named flow.
2388         https://bugs.webkit.org/show_bug.cgi?id=91307
2389
2390         Reviewed by Abhishek Arya.
2391
2392         The lifetime of a flow thread  has changed from not being destroyed (until the RenderView is destroyed) to being destroyed,
2393         under certain conditions, no attached regions and no content, before RenderView is destroyed.
2394         When the flow thread does not have any content and the region to be detached is the last region for the flow thread,
2395         the flow thread is destroyed.
2396         In this case, if the same region has to be attached again to the flow thread, the flow thread needs to be
2397         recreated, otherwise the crash will result.
2398
2399         Test: fast/regions/region-flow-reattach-crash.html
2400
2401         * rendering/RenderRegion.cpp:
2402         (WebCore::RenderRegion::attachRegion):
2403         We skip the attach if we are in the middle of document destruction.
2404         We recreate the flow thread to which the region is intended to be attached only if the region was
2405         not previously marked as invalid in relation to the flow thread (because the region was part of a
2406         circular dependency).
2407         (WebCore::RenderRegion::detachRegion): After the region is detached from flow thread,
2408         null the region internal pointer to the flow thread to mark that the region is not
2409         attached.
2410
2411 2012-08-02  Tommy Widenflycht  <tommyw@google.com>
2412
2413         MediaStream API: Move RTCConfiguration to its proper place
2414         https://bugs.webkit.org/show_bug.cgi?id=92867
2415
2416         Reviewed by Adam Barth.
2417
2418         This patch moves RTCConfiguration to Source/WebCore/platform/mediastream,
2419         and adds its WebKit interface for chromium.
2420
2421         No functional code changes.
2422
2423         * GNUmakefile.list.am:
2424         * Modules/mediastream/RTCPeerConnection.cpp:
2425         * WebCore.gypi:
2426         * platform/chromium/support/WebRTCConfiguration.cpp: Added.
2427         (WebKit):
2428         (WebKit::WebRTCICEServer::WebRTCICEServer):
2429         (WebKit::WebRTCICEServer::assign):
2430         (WebKit::WebRTCICEServer::reset):
2431         (WebKit::WebRTCICEServer::uri):
2432         (WebKit::WebRTCICEServer::credential):
2433         (WebKit::WebRTCConfiguration::WebRTCConfiguration):
2434         (WebKit::WebRTCConfiguration::assign):
2435         (WebKit::WebRTCConfiguration::reset):
2436         (WebKit::WebRTCConfiguration::numberOfServers):
2437         (WebKit::WebRTCConfiguration::server):
2438         * platform/mediastream/RTCConfiguration.h: Added.
2439         (WebCore):
2440         (RTCIceServer):
2441         (WebCore::RTCIceServer::create):
2442         (WebCore::RTCIceServer::~RTCIceServer):
2443         (WebCore::RTCIceServer::uri):
2444         (WebCore::RTCIceServer::credential):
2445         (WebCore::RTCIceServer::RTCIceServer):
2446         (RTCConfiguration):
2447         (WebCore::RTCConfiguration::create):
2448         (WebCore::RTCConfiguration::~RTCConfiguration):
2449         (WebCore::RTCConfiguration::appendServer):
2450         (WebCore::RTCConfiguration::numberOfServers):
2451         (WebCore::RTCConfiguration::server):
2452         (WebCore::RTCConfiguration::RTCConfiguration):
2453
2454 2012-08-02  Alexander Shalamov  <alexander.shalamov@intel.com>
2455
2456         [EFL] Browser crashes when non-progress element with -webkit-appearance:progress-bar is rendered
2457         https://bugs.webkit.org/show_bug.cgi?id=92747
2458
2459         Reviewed by Hajime Morita.
2460
2461         When https://bugs.webkit.org/show_bug.cgi?id=40158 was fixed, all ports
2462         were fixed except EFL port. This patch fixes assert that is hit when
2463         non-progress element is rendered with -webkit-appearance:progress-bar style.
2464
2465         * platform/efl/RenderThemeEfl.cpp:
2466         (WebCore::RenderThemeEfl::paintProgressBar):
2467
2468 2012-08-02  Yoshifumi Inoue  <yosin@chromium.org>
2469
2470         REGRESSION(r102741): [Forms] In selects, when disabled, browser skips first option if not in optgroup, then selects first option in optgroup
2471         https://bugs.webkit.org/show_bug.cgi?id=92833
2472
2473         Reviewed by Kent Tamura.
2474
2475         This patch changes implementation of HTMLOptionElement::disabled() to
2476         follow the "disabled" concept of option element in HTML5 specification[1],
2477         the option element is disabled if option element has "disabled"
2478         attribute or parent optgroup element has "disabled" attribute. Before
2479         this patch, HTMLOptionElement::disabled() checks presenting "disabled"
2480         attribute in option element itself and any parent element.
2481
2482         Before this patch, HTMLSelectElement::recalcListItems() didn't considers
2483         non-disabled option as default selected option if select element is
2484         disabled because HTMLOptionElement::disabled() returned true if select
2485         element is disabled.
2486
2487         After this patch, HTMLOptionElement::disabled() is independent from
2488         select element. HTMLSelectElement::recalcListItems() considers
2489         non-disabled option as default selected option.
2490
2491         [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/the-button-element.html#concept-option-disabled
2492
2493         Tests: fast/forms/basic-selects.html: Fixed expectation to right thing.
2494
2495         * css/html.css:
2496         (select[disabled]>option): Added to render option elements in disabled
2497         select element to disabled color as before this patch.
2498         * html/HTMLOptionElement.cpp:
2499         (WebCore::HTMLOptionElement::disabled): Changed to check parent element
2500         is optgroup.
2501         * html/HTMLSelectElement.cpp:
2502         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): On mouse up
2503         and down, don't update selection if select element is disabled.
2504         * rendering/RenderListBox.cpp:
2505         (WebCore::RenderListBox::paintItemForeground): Added checking select
2506         element is disabled. Before this patch, it was done by HTMLOptionElement::disabled().
2507
2508 2012-08-01  Sheriff Bot  <webkit.review.bot@gmail.com>
2509
2510         Unreviewed, rolling out r124406.
2511         http://trac.webkit.org/changeset/124406
2512         https://bugs.webkit.org/show_bug.cgi?id=92951
2513
2514         it set the Mac bots on fire (Requested by pizlo on #webkit).
2515
2516         * bindings/js/ScriptDebugServer.cpp:
2517         (WebCore::ScriptDebugServer::setBreakpoint):
2518         (WebCore::ScriptDebugServer::removeBreakpoint):
2519         (WebCore::ScriptDebugServer::hasBreakpoint):
2520         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
2521         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
2522         (WebCore::ScriptDebugServer::callEvent):
2523         (WebCore::ScriptDebugServer::atStatement):
2524         (WebCore::ScriptDebugServer::returnEvent):
2525         (WebCore::ScriptDebugServer::exception):
2526         (WebCore::ScriptDebugServer::willExecuteProgram):
2527         (WebCore::ScriptDebugServer::didExecuteProgram):
2528         (WebCore::ScriptDebugServer::didReachBreakpoint):
2529         * bindings/js/ScriptDebugServer.h:
2530         (ScriptDebugServer):
2531
2532 2012-08-01  Ilya Tikhonovsky  <loislo@chromium.org>
2533
2534         Web Inspector: test native memory instrumentation code with help of unittests
2535         https://bugs.webkit.org/show_bug.cgi?id=92743
2536
2537         Reviewed by Yury Semikhatsky.
2538
2539         Test a part of existing Native Memory Instrumentation code with help of unit tests.
2540         6 tests were added and two bugs were fixed.
2541         a drive-by improvement: the method MemoryInstrumentation::addInstrumentedObject
2542         was marked as private and addRootObject was introduced instead of it.
2543         The new function also calls processDeferedPointers.
2544
2545         * bindings/v8/ScriptProfiler.cpp:
2546         (WebCore::ScriptProfiler::collectBindingMemoryInfo):
2547         * dom/MemoryInstrumentation.h:
2548         (WebCore::MemoryInstrumentation::addRootObject):
2549         (MemoryInstrumentation):
2550         (WebCore::MemoryInstrumentation::addInstrumentedObject):
2551         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
2552         (WebCore):
2553         (WebCore::MemoryInstrumentation::addObjectImpl):
2554         * inspector/InspectorMemoryAgent.cpp:
2555         (WebCore):
2556         * inspector/MemoryInstrumentationImpl.h:
2557         (MemoryInstrumentationImpl):
2558         (WebCore::MemoryInstrumentationImpl::totalSize):
2559         (WebCore::MemoryInstrumentationImpl::reportedSizeForAllTypes):
2560
2561 2012-08-01  Ryosuke Niwa  <rniwa@webkit.org>
2562
2563         Chromium Android build fix after r124402.
2564         Initialize the out variables as suggested by the compiler.
2565
2566         * Modules/indexeddb/IDBLevelDBCoding.cpp:
2567         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::decode):
2568         (WebCore::IDBLevelDBCoding::DatabaseNameKey::decode):
2569         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::decode):
2570         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::decode):
2571         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::decode):
2572         (WebCore::IDBLevelDBCoding::IndexFreeListKey::decode):
2573         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::decode):
2574         (WebCore::IDBLevelDBCoding::IndexNamesKey::decode):
2575
2576 2012-08-01  Keishi Hattori  <keishi@webkit.org>
2577
2578         Fix typo in colorSuggestionPicker.js
2579         https://bugs.webkit.org/show_bug.cgi?id=92936
2580
2581         Reviewed by Kent Tamura.
2582
2583         Fixes typo.
2584
2585         Test: platform/chromium/fast/forms/color/color-suggestion-picker-with-scrollbar-appearance.html
2586
2587         * Resources/colorSuggestionPicker.js:
2588         (getScrollbarWidth):
2589
2590 2012-08-01  Shinya Kawanaka  <shinyak@chromium.org>
2591
2592         The elements in Shadow DOM of input should not be modifiable.
2593         https://bugs.webkit.org/show_bug.cgi?id=92200
2594
2595         Reviewed by Kent Tamura.
2596
2597         Since we don't have "-webkit-user-modify: read-only !important;" for the elements in Shadow DOM of
2598         input element, user can change them and it causes a crash.
2599
2600         We should have "-webkit-user-modify: read-only !important;" for those elements.
2601
2602         Test: fast/forms/input-user-modify.html
2603
2604         * css/html.css:
2605         (input::-webkit-textfield-decoration-container):
2606         (input[type="search"]::-webkit-search-cancel-button):
2607         (input[type="search"]::-webkit-search-decoration):
2608         (input[type="search"]::-webkit-search-results-decoration):
2609         (input[type="search"]::-webkit-search-results-button):
2610         (input::-webkit-inner-spin-button):
2611         (input::-webkit-input-speech-button):
2612         (input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
2613         (input[type="file"]::-webkit-file-upload-button):
2614         (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container):
2615         (input[type="range"]::-webkit-slider-runnable-track):
2616         (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb):
2617         (input[type="color"]::-webkit-color-swatch-wrapper):
2618         (input[type="color"]::-webkit-color-swatch):
2619         (input::-webkit-calendar-picker-indicator):
2620
2621 2012-08-01  Peter Wang  <peter.wang@torchmobile.com.cn>
2622
2623         Web Inspector: [JSC] implement setting breakpoints by line:column
2624         https://bugs.webkit.org/show_bug.cgi?id=53003
2625
2626         Reviewed by Geoffrey Garen.
2627
2628         As JSC is enabled to provide column info of statement, ScriptDebugServer can use it to
2629         support "Pretty Print" debug mode.
2630
2631         No new test case for this patch.
2632
2633         * bindings/js/ScriptDebugServer.cpp:
2634         (WebCore::ScriptDebugServer::setBreakpoint):
2635         (WebCore::ScriptDebugServer::removeBreakpoint):
2636         (WebCore):
2637         (WebCore::ScriptDebugServer::updateCurrentStatementPosition):
2638         (WebCore::ScriptDebugServer::hasBreakpoint):
2639         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
2640         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
2641         (WebCore::ScriptDebugServer::callEvent):
2642         (WebCore::ScriptDebugServer::atStatement):
2643         (WebCore::ScriptDebugServer::returnEvent):
2644         (WebCore::ScriptDebugServer::exception):
2645         (WebCore::ScriptDebugServer::willExecuteProgram):
2646         (WebCore::ScriptDebugServer::didExecuteProgram):
2647         (WebCore::ScriptDebugServer::didReachBreakpoint):
2648         * bindings/js/ScriptDebugServer.h:
2649         (ScriptDebugServer):
2650
2651 2012-08-01  Xingnan Wang  <xingnan.wang@intel.com>
2652
2653         IndexedDB: ObjectStoreMetaDataKey::m_metaDataType should use byte type
2654         https://bugs.webkit.org/show_bug.cgi?id=92725
2655
2656         Reviewed by Kentaro Hara.
2657
2658         No new tests - Low level functions covered by existing layout tests and also covered by Chromium
2659         webkit_unit_tests IDBLevelIDBCodingTest.*.
2660
2661         * Modules/indexeddb/IDBLevelDBCoding.cpp:
2662         (IDBLevelDBCoding):
2663         (WebCore::IDBLevelDBCoding::decodeByte):
2664         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::decode):
2665         (WebCore::IDBLevelDBCoding::DatabaseNameKey::decode):
2666         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::decode):
2667         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::encode):
2668         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::metaDataType):
2669         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::decode):
2670         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::decode):
2671         (WebCore::IDBLevelDBCoding::IndexFreeListKey::decode):
2672         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::decode):
2673         (WebCore::IDBLevelDBCoding::IndexNamesKey::decode):
2674         * Modules/indexeddb/IDBLevelDBCoding.h:
2675         (IDBLevelDBCoding):
2676
2677 2012-08-01  James Robinson  <jamesr@chromium.org>
2678
2679         [chromium] Use new-style tracing macros with explicit category
2680         https://bugs.webkit.org/show_bug.cgi?id=92928
2681
2682         Reviewed by Adam Barth.
2683
2684         The chromium tracing system supports using a string identifier for trace categories that can be used to filter
2685         events. This switches over to setting an explicit category for all traces and removes the old-style
2686         TRACE_EVENT() macro.
2687
2688         * bindings/v8/ScheduledAction.cpp:
2689         (WebCore::ScheduledAction::execute):
2690         * platform/ScrollAnimatorNone.cpp:
2691         (WebCore::ScrollAnimatorNone::scroll):
2692         (WebCore::ScrollAnimatorNone::animationTimerFired):
2693         * platform/chromium/TraceEvent.h:
2694         * platform/graphics/chromium/ProgramBinding.cpp:
2695         (WebCore::ProgramBindingBase::init):
2696         * platform/graphics/skia/ImageSkia.cpp:
2697         (WebCore::drawResampledBitmap):
2698         (WebCore::paintSkBitmap):
2699         (WebCore::Image::drawPattern):
2700         * platform/graphics/skia/NativeImageSkia.cpp:
2701         (WebCore::NativeImageSkia::resizedBitmap):
2702         * platform/graphics/skia/PlatformContextSkia.cpp:
2703         (WebCore::PlatformContextSkia::bitmap):
2704         * platform/image-decoders/bmp/BMPImageDecoder.cpp:
2705         (WebCore::BMPImageDecoder::decode):
2706         * platform/image-decoders/gif/GIFImageDecoder.cpp:
2707         (WebCore::GIFImageDecoder::decode):
2708         * platform/image-decoders/ico/ICOImageDecoder.cpp:
2709         (WebCore::ICOImageDecoder::decode):
2710         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
2711         (WebCore::JPEGImageDecoder::decode):
2712         * platform/image-decoders/png/PNGImageDecoder.cpp:
2713         (WebCore::PNGImageDecoder::decode):
2714         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
2715         (WebCore::WEBPImageDecoder::decode):
2716
2717 2012-08-01  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2718
2719         [EFL] Crash at WebCore::toRenderSlider
2720         https://bugs.webkit.org/show_bug.cgi?id=92893
2721
2722         Reviewed by Hajime Morita.
2723
2724         Added a type check before casting a render object to RenderSlider as 
2725         an arbitrary element can have for example webkit-appearance: slider-horizontal.
2726
2727         No new tests. Existing test fast/forms/range/slider-appearance-crash.html covers the case.
2728
2729         * platform/efl/RenderThemeEfl.cpp:
2730         (WebCore::RenderThemeEfl::paintThemePart):
2731
2732 2012-08-01  Koji Ishii  <kojiishi@gmail.com>
2733
2734         Cache support for OpenTypeVerticalData
2735         https://bugs.webkit.org/show_bug.cgi?id=81332
2736
2737         Reviewed by Tony Chang.
2738
2739         This patch adds FontCache to cache OpenTypeVerticalData class
2740         instances that was introduced in bug 81326.
2741
2742         We need one instance of the class per OpenType font file, and we don't
2743         have a class to hold such instances today.
2744
2745         ENABLE_OPENTYPE_VERTICAL isn't enabled for any platforms yet, so this
2746         patch isn't on any code path. Apple Windows port (bug 48459) is going
2747         to use this code, and probably Chromium (51450, 69282) as well.
2748
2749         "FIXME" comment in SimpleFontData.h will be implemented in 48459.
2750
2751         No new tests are required. No behavior changes.
2752
2753         * platform/graphics/FontCache.cpp:
2754         (WebCore::FontCache::getCachedFontPlatformData): Ignore leading "@" on Windows to disable Windows feature for vertical flow.
2755         (WebCore):
2756         (WebCore::FontCache::getVerticalData): Get cached OpenTypeVerticalData from FontPlatformData, or crete one.
2757         (WebCore::FontCache::purgeInactiveFontData): Purge inactive OpenTypeVerticalData.
2758         * platform/graphics/FontCache.h:
2759         (WebCore):
2760         * platform/graphics/SimpleFontData.h:
2761         (SimpleFontData):
2762         (WebCore::SimpleFontData::verticalData): A dummy implementation for purgeInactiveFontData() to work.
2763         * platform/graphics/opentype/OpenTypeVerticalData.h: Added m_inFontCache for mark & sweep.
2764         (OpenTypeVerticalData):
2765
2766 2012-08-01  James Robinson  <jamesr@chromium.org>
2767
2768         [chromium] Move compositor HUD font atlas initialization code out of compositor core
2769         https://bugs.webkit.org/show_bug.cgi?id=92924
2770
2771         Reviewed by Adrienne Walker.
2772
2773         This moves the HUD font atlas initialization code out of the compositor implementation to cut out Font-related
2774         dependencies. The new flow is that an embedder can pass a font atlas to the CCLayerTreeHost, after which the
2775         atlas is provided the HUD layer (if any) on the next commit. The HUD layer renders text using the font atlas if
2776         it has any if the settings require text.
2777
2778         HUD tested manually, we don't have automated tests for this debugging-only feature.
2779
2780         * platform/graphics/chromium/CompositorHUDFontAtlas.cpp:
2781         (WebCore):
2782         (WebCore::CompositorHUDFontAtlas::generateFontAtlas):
2783         * platform/graphics/chromium/CompositorHUDFontAtlas.h:
2784         (CompositorHUDFontAtlas):
2785         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.cpp:
2786         (WebCore::HeadsUpDisplayLayerChromium::create):
2787         (WebCore::HeadsUpDisplayLayerChromium::HeadsUpDisplayLayerChromium):
2788         (WebCore::HeadsUpDisplayLayerChromium::setFontAtlas):
2789         (WebCore):
2790         (WebCore::HeadsUpDisplayLayerChromium::createCCLayerImpl):
2791         (WebCore::HeadsUpDisplayLayerChromium::pushPropertiesTo):
2792         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.h:
2793         (HeadsUpDisplayLayerChromium):
2794         * platform/graphics/chromium/cc/CCFontAtlas.cpp:
2795         (WebCore::CCFontAtlas::CCFontAtlas):
2796         * platform/graphics/chromium/cc/CCFontAtlas.h:
2797         (WebCore):
2798         (WebCore::CCFontAtlas::create):
2799         (CCFontAtlas):
2800         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
2801         (WebCore::CCHeadsUpDisplayLayerImpl::CCHeadsUpDisplayLayerImpl):
2802         (WebCore::CCHeadsUpDisplayLayerImpl::setFontAtlas):
2803         (WebCore):
2804         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.h:
2805         (WebCore::CCHeadsUpDisplayLayerImpl::create):
2806         (CCHeadsUpDisplayLayerImpl):
2807         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2808         (WebCore::CCLayerTreeHost::setFontAtlas):
2809         (WebCore):
2810         (WebCore::CCLayerTreeHost::willCommit):
2811         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2812         (WebCore):
2813         (CCLayerTreeHost):
2814
2815 2012-08-01  Antoine Labour  <piman@chromium.org>
2816
2817         [chromium] factor out the optimization pass in CCRenderSurfaceFilters::apply
2818         https://bugs.webkit.org/show_bug.cgi?id=92453
2819
2820         Reviewed by James Robinson.
2821
2822         This separates the "optimization" pass in CCRenderSurfaceFilters::apply
2823         to resolve a succession of color matrix filters into a single operation.
2824         This allows testing of that code.
2825         This introduces a new generic color matrix WebFilterOperation, which can
2826         also be used on its own.
2827
2828         New test: CCRenderSurfaceFiltersTest.
2829
2830         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
2831         (WebCore::CCRenderSurfaceFilters::optimize):
2832         (WebCore):
2833         (WebCore::CCRenderSurfaceFilters::apply):
2834         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.h:
2835         (CCRenderSurfaceFilters):
2836
2837 2012-08-01  Jian Li  <jianli@chromium.org>
2838
2839         Add new CSS property "-webkit-widget-region" to expose dashboard region support for other port
2840         https://bugs.webkit.org/show_bug.cgi?id=90298
2841
2842         Reviewed by Adam Barth.
2843
2844         The css property "-webkit-widget-region" is essentially a synonym of
2845         "-webkit-dashboard-region" that allows us to expose dashboard region
2846         support for other port. This patch also adds a new feature define
2847         ENABLE(WIDGET_REGION) such that "-webkit-dashboard-region" is only
2848         provided under ENABLE(DASHBOARD_SUPPORT) as it is now and
2849         "-webkit-widget-region" is only exposed under ENABLE(WIDGET_REGION).
2850
2851         Change almost all the code pieces guarded by ENABLE(DASHBOARD_SUPPORT)
2852         to make them also guarded by ENABLE(WIDGET_REGION), except those
2853         that are specific to Apple/WebKit.
2854
2855         Currently ENABLE(WIDGET_REGION) has been turned on by default for
2856         Mac/WebKit and chromium ports.
2857
2858         Test: fast/css/widget-region-parser.html
2859
2860         * Configurations/FeatureDefines.xcconfig: Add ENABLE_WIDGET_REGION define.
2861         * DerivedSources.make:
2862         * GNUmakefile.am: Add ENABLE_WIDGET_REGION define.
2863         * WebCore.exp.in:
2864         * css/CSSComputedStyleDeclaration.cpp: Handle CSSPropertyWebkitWidgetRegion.
2865         (WebCore):
2866         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2867         * css/CSSParser.cpp: Parse "-webkit-widget-region".
2868         (WebCore::CSSParser::parseValue):
2869         (WebCore):
2870         (WebCore::CSSParser::parseDashboardRegions):
2871         * css/CSSProperty.cpp: Handle CSSPropertyWebkitWidgetRegion.
2872         (WebCore::CSSProperty::isInheritedProperty):
2873         * css/CSSPrimitiveValue.cpp:
2874         (WebCore):
2875         (WebCore::CSSPrimitiveValue::customCssText):
2876         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
2877         * css/CSSPropertyNames.in: Add "-webkit-widget-region" property.
2878         * css/DashboardRegion.h:
2879         (DashboardRegion):
2880         * css/StyleResolver.cpp: Handle CSSPropertyWebkitWidgetRegion.
2881         * dom/Document.cpp:
2882         (WebCore::Document::Document):
2883         (WebCore):
2884         * dom/Document.h:
2885         (WebCore):
2886         (Document):
2887         * page/Chrome.cpp:
2888         (WebCore):
2889         * page/ChromeClient.h:
2890         (ChromeClient):
2891         * page/FrameView.cpp:
2892         (WebCore::FrameView::layout):
2893         (WebCore):
2894         (WebCore::FrameView::paintContents):
2895         * page/FrameView.h:
2896         (FrameView):
2897         * rendering/RenderInline.cpp:
2898         (WebCore):
2899         * rendering/RenderInline.h:
2900         (RenderInline):
2901         * rendering/RenderLayer.cpp:
2902         (WebCore::RenderLayer::scrollTo):
2903         (WebCore::RenderLayer::setHasHorizontalScrollbar):
2904         (WebCore::RenderLayer::setHasVerticalScrollbar):
2905         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
2906         * rendering/RenderListBox.cpp:
2907         (WebCore::RenderListBox::setHasVerticalScrollbar):
2908         * rendering/RenderObject.cpp:
2909         (WebCore::RenderObject::styleWillChange):
2910         (WebCore):
2911         * rendering/RenderObject.h:
2912         (RenderObject):
2913         * rendering/style/RenderStyle.cpp:
2914         (WebCore::RenderStyle::diff):
2915         (WebCore):
2916         * rendering/style/RenderStyle.h:
2917         * rendering/style/StyleDashboardRegion.h:
2918         * rendering/style/StyleRareNonInheritedData.cpp:
2919         (WebCore::StyleRareNonInheritedData::operator==):
2920         * rendering/style/StyleRareNonInheritedData.h:
2921         (WebCore):
2922         (StyleRareNonInheritedData):
2923
2924 2012-08-01  Arnaud Renevier  <a.renevier@sisa.samsung.com>
2925
2926         [V8] TypedArray binding performance improvements
2927         https://bugs.webkit.org/show_bug.cgi?id=92557
2928
2929         Reviewed by Kenneth Russell.
2930
2931         Improve TypedArray bindings performance:
2932         - create arrays with createUninitialized when possible. Typed Array
2933         construction is about 10% faster.
2934         - when creating a typed array from a same typed array, memcpy data
2935         from source to target.
2936
2937         In order to detect if argument array is the same type as
2938         implementation array, we pass the javascript wrapper type as a new
2939         type argument to template function constructWebGLArray.
2940
2941         Introduce wrapArrayBufferView which wraps typed array into a v8::Value
2942
2943         No new tests: Performance tests are already handled by
2944         Bindings/typed-array-construct-from-same-type.html and
2945         Bindings/typed-array-construct-from-typed.html
2946
2947         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
2948         (WebCore):
2949         (WebCore::constructWebGLArray):
2950         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
2951         (WebCore::V8Float32Array::constructorCallback):
2952         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
2953         (WebCore::V8Float64Array::constructorCallback):
2954         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
2955         (WebCore::V8Int16Array::constructorCallback):
2956         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
2957         (WebCore::V8Int32Array::constructorCallback):
2958         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
2959         (WebCore::V8Int8Array::constructorCallback):
2960         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
2961         (WebCore::V8Uint16Array::constructorCallback):
2962         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
2963         (WebCore::V8Uint32Array::constructorCallback):
2964         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
2965         (WebCore::V8Uint8Array::constructorCallback):
2966         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
2967         (WebCore::V8Uint8ClampedArray::constructorCallback):
2968
2969 2012-08-01  Antoine Labour  <piman@chromium.org>
2970
2971         [chromium] Fix lost context handling on hud layer
2972         https://bugs.webkit.org/show_bug.cgi?id=92915
2973
2974         Reviewed by Adrienne Walker.
2975
2976         On lost context we need to release CCScopedTextures, otherwise later on
2977         we will try to re-allocate it using a stale CCResourceProvider.
2978
2979         Test CCLayerTreeHostImplTest.dontUseOldResourcesAfterLostContext
2980         extended.
2981
2982         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
2983         (WebCore::CCHeadsUpDisplayLayerImpl::didLoseContext):
2984         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.h:
2985
2986 2012-08-01  Kwang Yul Seo  <skyul@company100.net>
2987
2988         Read tag names and attributes from the saved tokens in HTMLElementStack
2989         https://bugs.webkit.org/show_bug.cgi?id=92830
2990
2991         Reviewed by Adam Barth.
2992
2993         This is a follow-up patch for r123577.
2994         Replaced top()->hasTagName(x) with topStackItem()->hasTagName(x).
2995         Also replaced item->element()->hasTagName(x) with item->hasTagName(x).
2996
2997         No new tests, covered by existing tests.
2998
2999         * html/parser/HTMLElementStack.cpp:
3000         (WebCore::HTMLElementStack::pop):
3001         (WebCore::HTMLElementStack::popUntil):
3002         (WebCore::HTMLElementStack::pushHTMLHtmlElement):
3003         (WebCore::HTMLElementStack::pushHTMLHeadElement):
3004         (WebCore::HTMLElementStack::pushHTMLBodyElement):
3005         (WebCore::HTMLElementStack::push):
3006         (WebCore::HTMLElementStack::insertAbove):
3007         (WebCore::HTMLElementStack::popCommon):
3008
3009 2012-08-01  Antoine Labour  <piman@chromium.org>
3010
3011         [chromium] remove unused fields from LayerRendererCapabilities
3012         https://bugs.webkit.org/show_bug.cgi?id=92906
3013
3014         Reviewed by James Robinson.
3015
3016         No new tests (just removing dead code).
3017
3018         * platform/graphics/chromium/LayerRendererChromium.cpp:
3019         (WebCore::LayerRendererChromium::initialize):
3020         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
3021         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
3022         (LayerRendererCapabilities):
3023
3024 2012-08-01  James Robinson  <jamesr@chromium.org>
3025
3026         [chromium] Move compositor HUD font atlas generation out of compositor core
3027         https://bugs.webkit.org/show_bug.cgi?id=92901
3028
3029         Reviewed by Adrienne Walker.
3030
3031         This moves the font atlas generation out of CCFontAtlas into a separate helper class and ports the CCFontAtlas
3032         text drawing code over to use skia directly.
3033
3034         * WebCore.gypi:
3035         * platform/graphics/chromium/CompositorHUDFontAtlas.cpp: Added.
3036         (WebCore):
3037         (WebCore::wrapPositionIfNeeded):
3038         (WebCore::CompositorHUDFontAtlas::generateFontAtlas):
3039         * platform/graphics/chromium/CompositorHUDFontAtlas.h: Added.
3040         (WebCore):
3041         (CompositorHUDFontAtlas):
3042         * platform/graphics/chromium/cc/CCFontAtlas.cpp:
3043         (WebCore::CCFontAtlas::CCFontAtlas):
3044         (WebCore::CCFontAtlas::~CCFontAtlas):
3045         (WebCore::CCFontAtlas::initialize):
3046         (WebCore::CCFontAtlas::drawText):
3047         (WebCore::CCFontAtlas::drawOneLineOfTextInternal):
3048         (WebCore::CCFontAtlas::drawDebugAtlas):
3049         * platform/graphics/chromium/cc/CCFontAtlas.h:
3050         (WebCore):
3051         (CCFontAtlas):
3052         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
3053
3054 2012-08-01  Peter Beverloo  <peter@chromium.org>
3055
3056         [Text Autosizing] Provide an API for influencing the font scale factor
3057         https://bugs.webkit.org/show_bug.cgi?id=92882
3058
3059         Reviewed by Adam Barth.
3060
3061         Add the font scale factor to settings, and provide an API in
3062         window.internal.settings to change it from layout tests.
3063
3064         The font scale factor applied to Text Autosizing influences the sizing
3065         of text, and will influence the scaling of boosted blocks once the
3066         implementation progresses. For Android, it will be set to the font size
3067         chosen in the user's system-wide preferences.
3068
3069         Test: fast/text-autosizing/font-scale-factor.html
3070
3071         * page/Settings.cpp:
3072         (WebCore::Settings::Settings):
3073         (WebCore):
3074         (WebCore::Settings::setTextAutosizingFontScaleFactor):
3075         * page/Settings.h:
3076         (Settings):
3077         (WebCore::Settings::textAutosizingFontScaleFactor):
3078         * rendering/TextAutosizer.cpp:
3079         (WebCore::TextAutosizer::processBlock):
3080         * testing/InternalSettings.cpp:
3081         (WebCore::InternalSettings::Backup::Backup):
3082         (WebCore::InternalSettings::Backup::restoreTo):
3083         (WebCore::InternalSettings::setTextAutosizingFontScaleFactor):
3084         (WebCore):
3085         * testing/InternalSettings.h:
3086         (Backup):
3087         (InternalSettings):
3088         * testing/InternalSettings.idl:
3089
3090 2012-08-01  Mike West  <mkwst@chromium.org>
3091
3092         CSP should correctly block plugin resources rendered in PluginDocuments.
3093         https://bugs.webkit.org/show_bug.cgi?id=92675
3094
3095         Reviewed by Adam Barth.
3096
3097         In certain cases, plugins aren't loaded directly, but are stuffed into a
3098         newly-created PluginDocument before rendering. While we were already
3099         correctly populating information that allowed us to make decisions about
3100         that document's security origin, and already dealing with sandbox
3101         status by creating a 'SinkDocument' that ignored plugin data, we weren't
3102         correctly inheriting the parent frame's Content Security Policy. This
3103         patch ensures that PluginDocuments correctly inherit their parent's
3104         Content Security Policy, meaning that the plugin is blocked or allowed
3105         according to the policy of the protected resource in which the
3106         PluginDocument is embedded.
3107
3108         Tests: http/tests/security/contentSecurityPolicy/object-src-url-allowed.html
3109                http/tests/security/contentSecurityPolicy/object-src-url-blocked.html
3110
3111         * dom/Document.cpp:
3112         (WebCore::Document::initContentSecurityPolicy):
3113             Populate a created PluginDocument with its frame's parent's Content
3114             Security Policy.
3115
3116 2012-08-01  Florin Malita  <fmalita@chromium.org>
3117
3118         SVG animation not working for elements inserted after parsing is finished
3119         https://bugs.webkit.org/show_bug.cgi?id=92025
3120
3121         Reviewed by Nikolas Zimmermann.
3122
3123         Time containers for SVG elements inserted after document parsing is finished need to be
3124         initialized on insertion (since they've missed the Document::implicitClose() initialization
3125         point).
3126
3127         Test: svg/animations/deferred-insertion.html
3128
3129         * svg/SVGSVGElement.cpp:
3130         (WebCore::SVGSVGElement::insertedInto):
3131
3132 2012-08-01  Vincent Scheib  <scheib@chromium.org>
3133
3134         Block pointer lock for sandboxed iframes.
3135         https://bugs.webkit.org/show_bug.cgi?id=92796
3136
3137         Reviewed by Adam Barth.
3138
3139         Sandboxed iframe documents should be blocked from using the
3140         pointer lock API until there is specification agreement
3141         on what attribute to use to allow the feature. After
3142         specification this restriction can be relaxed, but not
3143         restricting it now would require breaking applications
3144         later.
3145
3146         Test: http/tests/pointer-lock/iframe-sandboxed.html
3147
3148         * dom/SecurityContext.h:
3149         * page/PointerLockController.cpp:
3150         (WebCore::PointerLockController::requestPointerLock):
3151
3152 2012-08-01  Patrick Gansterer  <paroga@webkit.org>
3153
3154         Replace WTF::getCurrentLocalTime() with GregorianDateTime::setToCurrentLocalTime()
3155         https://bugs.webkit.org/show_bug.cgi?id=92286
3156
3157         Reviewed by Geoffrey Garen.
3158
3159         Add a method to GregorianDateTime to set its values to the current locale time.
3160         Replacing all occurrences of getCurrentLocalTime with the new function allows
3161         us to remove getCurrentLocalTime in a next step.
3162
3163         * html/FTPDirectoryDocument.cpp:
3164         (WebCore::processFileDateString):
3165         * loader/archive/mhtml/MHTMLArchive.cpp:
3166         (WebCore::MHTMLArchive::generateMHTMLData):
3167
3168 2012-08-01  Ojan Vafai  <ojan@chromium.org>
3169
3170         Remove code duplication in determining if display is inline or replaced
3171         https://bugs.webkit.org/show_bug.cgi?id=92880
3172
3173         Reviewed by Julien Chaffraix.
3174
3175         Deduplicate lists of display types by using private helpers.
3176
3177         No new tests. No change in behavior.
3178
3179         * rendering/style/RenderStyle.h:
3180
3181 2012-08-01  Tommy Widenflycht  <tommyw@google.com>
3182
3183         MediaStream API: Add ExtraData capability to MediaStreamSource
3184         https://bugs.webkit.org/show_bug.cgi?id=92860
3185
3186         Reviewed by Adam Barth.
3187
3188         The Chromium port needs to store some related data in MediaStreamSource objects.
3189
3190         Not testable from a LayoutTest.
3191
3192         * platform/chromium/support/WebMediaStreamSource.cpp:
3193         (ExtraDataContainer):
3194         (WebKit::ExtraDataContainer::ExtraDataContainer):
3195         (WebKit::ExtraDataContainer::extraData):
3196         (WebKit):
3197         (WebKit::WebMediaStreamSource::extraData):
3198         (WebKit::WebMediaStreamSource::setExtraData):
3199         * platform/mediastream/MediaStreamSource.h:
3200         (ExtraData):
3201         (WebCore::MediaStreamSource::ExtraData::~ExtraData):
3202         (MediaStreamSource):
3203         (WebCore::MediaStreamSource::extraData):
3204         (WebCore::MediaStreamSource::setExtraData):
3205
3206 2012-08-01  Joshua Bell  <jsbell@chromium.org>
3207
3208         IndexedDB: IDBCursor.continue(key) does not throw for key "behind" cursor
3209         https://bugs.webkit.org/show_bug.cgi?id=92562
3210
3211         Reviewed by Ojan Vafai.
3212
3213         Per spec, IDBCursor.continue(key) should throw for forward cursors
3214         if key <= current key, and for reverse cursors if key >= current key.
3215         Code was present on the back end but the error code was ignored, possibly
3216         broken in a recent refactor, and there were no tests for this case.
3217
3218         Test: storage/indexeddb/cursor-continue-dir.html
3219
3220         * Modules/indexeddb/IDBCursor.cpp:
3221         (WebCore::IDBCursor::advance): Handle async transaction termination.
3222         (WebCore::IDBCursor::continueFunction): Move checks here from backend.
3223         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
3224         (WebCore::IDBCursorBackendImpl::IDBCursorBackendImpl): Don't need direction param.
3225         (WebCore::IDBCursorBackendImpl::continueFunction): Remove checks.
3226         * Modules/indexeddb/IDBCursorBackendImpl.h: Only IDBBackingStore::cursor needs direction now.
3227         (WebCore::IDBCursorBackendImpl::create):
3228         (IDBCursorBackendImpl):
3229         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
3230         (WebCore::IDBIndexBackendImpl::openCursorInternal): Drop unused param.
3231         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
3232         (WebCore::IDBObjectStoreBackendImpl::openCursorInternal): Ditto.
3233
3234 2012-08-01  Rick Byers  <rbyers@chromium.org>
3235
3236         Don't request a clickCount of 1 on mouseMove event generated by tap gestures
3237         https://bugs.webkit.org/show_bug.cgi?id=92779
3238
3239         Reviewed by Adam Barth.
3240
3241         mousemove events don't have a click count, so we shouldn't be passing 1
3242         here.  Note this makes no real difference in practice since the value is
3243         ignored - fixed strictly for pedantics.
3244         
3245         Test: fast/events/touch/gesture/gesture-click
3246
3247         * page/EventHandler.cpp:
3248         (WebCore::EventHandler::handleGestureTap):
3249
3250 2012-08-01  Kihong Kwon  <kihong.kwon@samsung.com>
3251
3252         Dropping webkit prefix from Vibration API
3253         https://bugs.webkit.org/show_bug.cgi?id=92840
3254
3255         Reviewed by Adam Barth.
3256
3257         Remove webkit prefix from navigator.webkitVibrate().
3258         - Vibration API have been entered CR already.
3259         - Firefox already implements Vibration API.
3260
3261         No new tests. Covered by fast/dom/navigator-vibration.html
3262
3263         * Modules/vibration/NavigatorVibration.cpp:
3264         (WebCore::NavigatorVibration::vibrate):
3265         * Modules/vibration/NavigatorVibration.h:
3266         (NavigatorVibration):
3267         * Modules/vibration/NavigatorVibration.idl:
3268
3269 2012-08-01  Kwang Yul Seo  <skyul@company100.net>
3270
3271         Read tag names and attributes from the saved tokens in HTMLFormattingElementList::closestElementInScopeWithName(const AtomicString&)
3272         https://bugs.webkit.org/show_bug.cgi?id=92841
3273
3274         Reviewed by Adam Barth.
3275
3276         This is a follow-up patch for r123577.
3277         Replaced entry.element()->hasLocalName(targetName) with entry.stackItem()->hasLocalName(targetName).
3278
3279         No new tests, covered by existing tests.
3280
3281         * html/parser/HTMLFormattingElementList.cpp:
3282         (WebCore::HTMLFormattingElementList::closestElementInScopeWithName):
3283
3284 2012-08-01  Kwang Yul Seo  <skyul@company100.net>
3285
3286         HTMLTreeBuilder passes a wrong token when pushing the head element
3287         https://bugs.webkit.org/show_bug.cgi?id=92838
3288
3289         Reviewed by Adam Barth.
3290
3291         When the tree builder pushes the head element in the "after head" insertion mode,
3292         it creates a HTMLStackItem from a wrong token.
3293
3294         Added HTMLConstructionSite::headStackItem() to retrieve the stack item for the head
3295         element. Modified the tree builder to pass the correct stack item when pushing the head
3296         element in the "after head" insertion mode.
3297
3298         No new tests, covered by existing tests.
3299
3300         * html/parser/HTMLConstructionSite.cpp:
3301         (WebCore::HTMLConstructionSite::insertHTMLHeadElement):
3302         * html/parser/HTMLConstructionSite.h:
3303         (WebCore::HTMLConstructionSite::head):
3304         (WebCore::HTMLConstructionSite::headStackItem):
3305         (HTMLConstructionSite):
3306         * html/parser/HTMLTreeBuilder.cpp:
3307         (WebCore::HTMLTreeBuilder::processStartTag):
3308
3309 2012-08-01  Andrei Bucur  <abucur@adobe.com>
3310
3311         [CSS Regions] The regionLayoutUpdate event should be dispatched on the NamedFlow object
3312         https://bugs.webkit.org/show_bug.cgi?id=88778
3313
3314         Reviewed by Adam Barth.
3315
3316         Spec: http://www.w3.org/TR/css3-regions/#region-flow-layout-events
3317
3318         This patch implements the regionLayoutUpdate event per May 3rd CSS Regions spec recommendation.
3319         Before this patch the event was dispatched individually on each region whenever its overflow state changed. The trigger conditions are preserved with the following additions:
3320         - the event is dispatched when the last region is removed
3321         - the event is not dispatched when the named flow switches to the NULL state
3322         Also, the NamedFlow objects are not deleted if they switch to the NULL state and have listeners attached. In that scenario the JS wrapper will not release the reference
3323         until the parent Document is destroyed.
3324
3325         Tests: The old tests have been modified to use the event on the NamedFlow object rather the one on the Region. New tests have been added to verify the
3326         correct behavior in the special states of the NamedFlow (no region chain, NULL state).
3327
3328         * dom/Document.cpp:
3329         (WebCore::Document::addListenerTypeIfNeeded): Listeners are not added on Nodes any more so the regionLayoutUpdate type was removed from the list.
3330         * dom/Document.h:
3331         * dom/EventTarget.h:
3332         (WebCore):
3333         * dom/EventTargetFactory.in:
3334         * dom/Node.cpp:
3335         * dom/Node.h:
3336         (Node):
3337         * dom/WebKitNamedFlow.cpp:
3338         (WebCore::WebKitNamedFlow::eventTargetData):
3339         (WebCore):
3340         (WebCore::WebKitNamedFlow::ensureEventTargetData):
3341         (WebCore::WebKitNamedFlow::dispatchRegionLayoutUpdateEvent): The 3rd May WD says the event is bubbling. However this doesn't make sense as this object doesn't belong to the DOM tree. This was fixed in the ED.
3342         (WebCore::WebKitNamedFlow::interfaceName):
3343         (WebCore::WebKitNamedFlow::scriptExecutionContext):
3344         (WebCore::WebKitNamedFlow::base): Getter for the owner Document used by the wrapper to determine if the object is reachable.
3345         * dom/WebKitNamedFlow.h:
3346         (WebCore):
3347         (WebKitNamedFlow):
3348         (WebCore::WebKitNamedFlow::refEventTarget):
3349         (WebCore::WebKitNamedFlow::derefEventTarget):
3350         * dom/WebKitNamedFlow.idl:
3351         * rendering/RenderFlowThread.cpp:
3352         (WebCore::RenderFlowThread::RenderFlowThread):
3353         (WebCore::RenderFlowThread::layout): The event dispatching is now handled by the implementation of RenderFlowThread.
3354         (WebCore::RenderFlowThread::computeOverflowStateForRegions):
3355         * rendering/RenderFlowThread.h:
3356         * rendering/RenderNamedFlowThread.cpp:
3357         (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
3358         (WebCore::RenderNamedFlowThread::removeRegionFromThread): The layout doesn't detect changes caused by removing the last region. This case is handled separately.
3359         (WebCore::RenderNamedFlowThread::dispatchRegionLayoutUpdateEvent):
3360         (WebCore):
3361         (WebCore::RenderNamedFlowThread::regionLayoutUpdateEventTimerFired):
3362         * rendering/RenderNamedFlowThread.h:
3363         (RenderNamedFlowThread):
3364         * rendering/RenderRegion.cpp:
3365         (WebCore::RenderRegion::RenderRegion):
3366         * rendering/RenderRegion.h:
3367         (RenderRegion):
3368
3369 2012-07-31  Robert Hogan  <robert@webkit.org>
3370
3371         CSS 2.1 failure: margin-collapse-012 fails
3372         https://bugs.webkit.org/show_bug.cgi?id=80219
3373
3374         Reviewed by Eric Seidel.
3375
3376         Tests: css2.1/20110323/margin-collapse-012.htm
3377                fast/css/margin-collapse-abspos-negmargin.htm
3378
3379         I also ran this against the full margin-collapse-* CSS 2.1 suite without regressions.
3380
3381         Per http://www.w3.org/TR/CSS21/box.html#collapsing-margins don't collapse the margins of 
3382         positioned blocks. Instead, just use the margin of the sibling/container to offset the 
3383         positioned block's logical top - its own margin gets added in later at 
3384         RenderBox::computePositionedLogicalHeightUsing().
3385
3386         * rendering/RenderBlock.cpp:
3387         (WebCore::RenderBlock::adjustPositionedBlock):
3388
3389 2012-08-01  Sheriff Bot  <webkit.review.bot@gmail.com>
3390
3391         Unreviewed, rolling out r124334.
3392         http://trac.webkit.org/changeset/124334
3393         https://bugs.webkit.org/show_bug.cgi?id=92879
3394
3395         Broke MemoryInstrumentationTest.sizeOf from webkit_unit_tests
3396         on Chromium canaries (Requested by apavlov1 on #webkit).
3397
3398         * bindings/v8/ScriptProfiler.cpp:
3399         (WebCore::ScriptProfiler::collectBindingMemoryInfo):
3400         * dom/MemoryInstrumentation.h:
3401         (WebCore::MemoryInstrumentation::addInstrumentedObject):
3402         (MemoryInstrumentation):
3403         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
3404         * inspector/InspectorMemoryAgent.cpp:
3405         (WebCore):
3406         * inspector/MemoryInstrumentationImpl.h:
3407         (MemoryInstrumentationImpl):
3408         (WebCore::MemoryInstrumentationImpl::totalTypeSize):
3409
3410 2012-08-01  Han Shen  <shenhan@google.com>
3411
3412         Fix gcc 4.7 compile warnings.
3413         https://bugs.webkit.org/show_bug.cgi?id=92797
3414
3415         Reviewed by Kentaro Hara.
3416
3417         GCC 4.7 gives (more strict) warnings on uninitialized variables,
3418         fixed by providing initilization values.
3419
3420         Tested by gcc 4.7 building. No change in behavior.
3421
3422         * platform/graphics/filters/arm/NEONHelpers.h:
3423         (WebCore::loadRGBA8AsFloat): Add initilizaton value for local variable.
3424
3425 2012-08-01  Ryosuke Niwa  <rniwa@webkit.org>
3426
3427         REGRESSION(r122498): Assertion failure: m_nodeListCounts is sometimes not zero in the Document destructor
3428         https://bugs.webkit.org/show_bug.cgi?id=92742
3429
3430         Reviewed by Andreas Kling.
3431
3432         The bug was caused by adoptTreeScope's not always calling unregisterNodeListCache and registerNodeListCache
3433         on node lists that use m_atomicNameCaches and m_nameCaches.
3434
3435         Tests: fast/dom/NodeList/nodelist-moved-to-fragment-2.html
3436                fast/dom/NodeList/nodelist-moved-to-fragment.html
3437
3438         * dom/NodeRareData.h:
3439         (WebCore::NodeListsNodeData::adoptTreeScope):
3440
3441 2012-08-01  Vsevolod Vlasov  <vsevik@chromium.org>
3442
3443         Web Inspector: Crashes in NetworkResourcesData.
3444         https://bugs.webkit.org/show_bug.cgi?id=92874
3445
3446         Reviewed by Yury Semikhatsky.
3447
3448         * inspector/NetworkResourcesData.cpp:
3449         (WebCore::contentSizeInBytes):
3450         (WebCore):
3451         (WebCore::NetworkResourcesData::ResourceData::removeContent):
3452         (WebCore::NetworkResourcesData::ResourceData::decodeDataToContent):
3453         (WebCore::NetworkResourcesData::setResourceContent):
3454         (WebCore::NetworkResourcesData::maybeDecodeDataToContent):
3455
3456 2012-08-01  Ilya Tikhonovsky  <loislo@chromium.org>
3457
3458         Web Inspector: test native memory instrumentation code with help of unittests
3459         https://bugs.webkit.org/show_bug.cgi?id=92743
3460
3461         Reviewed by Yury Semikhatsky.
3462
3463         Test a part of existing Native Memory Instrumentation code with help of unit tests.
3464         6 tests were added and two bugs were fixed.
3465         a drive-by improvement: the method MemoryInstrumentation::addInstrumentedObject
3466         was marked as private and addRootObject was introduced instead of it.
3467         The new function also calls processDeferedPointers.
3468
3469         * bindings/v8/ScriptProfiler.cpp:
3470         (WebCore::ScriptProfiler::collectBindingMemoryInfo):
3471         * dom/MemoryInstrumentation.h:
3472         (WebCore::MemoryInstrumentation::addRootObject):
3473         (MemoryInstrumentation):
3474         (WebCore::MemoryInstrumentation::addInstrumentedObject):
3475         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
3476         (WebCore):
3477         (WebCore::MemoryInstrumentation::addObjectImpl):
3478         * inspector/InspectorMemoryAgent.cpp:
3479         (WebCore):
3480         * inspector/MemoryInstrumentationImpl.h:
3481         (MemoryInstrumentationImpl):
3482
3483 2012-08-01  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
3484
3485         [GTK] Memory leak found while running webaudio tests
3486         https://bugs.webkit.org/show_bug.cgi?id=92861
3487
3488         Reviewed by Philippe Normand.
3489
3490         Fix a memory leak in decodeAudioForBusCreation by adopting
3491         an allocation of GInputStream.
3492
3493         No new tests. No change in behavior.
3494
3495         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
3496         (WebCore::AudioFileReader::decodeAudioForBusCreation):
3497
3498 2012-08-01  Alexei Filippov  <alexeif@chromium.org>
3499
3500         Web Inspector: count DOM storage cache memory for native snapshot
3501         https://bugs.webkit.org/show_bug.cgi?id=91617
3502
3503         Reviewed by Yury Semikhatsky.
3504
3505         Add memory size used for DOM storage cache reporting interface.
3506         Report it to the native memory snapshot instrumentation framework.
3507
3508         * inspector/InspectorController.cpp:
3509         (WebCore::InspectorController::InspectorController):
3510         * inspector/InspectorDOMStorageAgent.cpp:
3511         (WebCore::InspectorDOMStorageAgent::memoryBytesUsedByStorageCache):
3512         (WebCore):
3513         * inspector/InspectorDOMStorageAgent.h:
3514         (InspectorDOMStorageAgent):
3515         * inspector/InspectorMemoryAgent.cpp:
3516         (MemoryBlockName):
3517         (WebCore):
3518         (WebCore::dumpDOMStorageCache):
3519         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
3520         (WebCore::InspectorMemoryAgent::InspectorMemoryAgent):
3521         * inspector/InspectorMemoryAgent.h:
3522         (WebCore):
3523         (WebCore::InspectorMemoryAgent::create):
3524         (InspectorMemoryAgent):
3525         * inspector/front-end/NativeMemorySnapshotView.js:
3526         (WebInspector.MemoryBlockViewProperties._initialize):
3527         * storage/StorageArea.h:
3528         (StorageArea):
3529         * storage/StorageAreaImpl.cpp:
3530         (WebCore::StorageAreaImpl::memoryBytesUsedByCache):
3531         (WebCore):
3532         * storage/StorageAreaImpl.h:
3533         (StorageAreaImpl):
3534
3535 2012-07-31  Yury Semikhatsky  <yurys@chromium.org>
3536
3537         Web Inspector: add CSSStyleSheet memory instrumentation
3538         https://bugs.webkit.org/show_bug.cgi?id=92748
3539
3540         Reviewed by Antti Koivisto.
3541
3542         Added MemoryInstrumentation for CSSStyleSheet, StyleSheetContents, StyleRule,
3543         CSSSelectorList and StylePropertySet. The coverage is not complete as the
3544         patch was growing too big.
3545
3546         * css/CSSSelectorList.cpp:
3547         (WebCore::CSSSelectorList::CSSSelectorList):
3548         (WebCore::CSSSelectorList::length):
3549         (WebCore):
3550         (WebCore::CSSSelectorList::reportMemoryUsage):
3551         * css/CSSSelectorList.h:
3552         (WebCore):
3553         (CSSSelectorList):
3554         * css/CSSStyleSheet.cpp:
3555         (WebCore::CSSStyleSheet::reportMemoryUsage):
3556         (WebCore):
3557         * css/CSSStyleSheet.h:
3558         (WebCore):
3559         (CSSStyleSheet):
3560         * css/MediaList.cpp:
3561         (WebCore):
3562         (WebCore::MediaQuerySet::reportMemoryUsage):
3563         (WebCore::MediaList::reportMemoryUsage):
3564         * css/MediaList.h:
3565         (WebCore):
3566         (MediaQuerySet):
3567         (MediaList):
3568         * css/MediaQuery.cpp:
3569         (WebCore::MediaQuery::reportMemoryUsage):
3570         (WebCore):
3571         * css/MediaQuery.h:
3572         (WebCore):
3573         (MediaQuery):
3574         * css/MediaQueryExp.cpp:
3575         (WebCore::MediaQueryExp::reportMemoryUsage):
3576         (WebCore):
3577         * css/MediaQueryExp.h:
3578         (WebCore):
3579         (MediaQueryExp):
3580         * css/StylePropertySet.cpp:
3581         (WebCore::StylePropertySet::reportMemoryUsage):
3582         (WebCore):
3583         * css/StylePropertySet.h:
3584         (WebCore):
3585         (StylePropertySet):
3586         * css/StyleRule.cpp:
3587         (WebCore::StyleRuleBase::reportMemoryUsage): We cannot make
3588         reportMemoryUsage virtual as it would add vtable to StyleRuleBase
3589         and its descendants and would blow its memory footprint. This
3590         is why we have a switch over StyleRule type here.
3591         (WebCore):
3592         (WebCore::StyleRule::reportMemoryUsage):
3593         (WebCore::StyleRulePage::reportMemoryUsage):
3594         (WebCore::StyleRuleFontFace::reportMemoryUsage):
3595         (WebCore::StyleRuleBlock::reportMemoryUsage):
3596         (WebCore::StyleRuleMedia::reportMemoryUsage):
3597         (WebCore::StyleRuleRegion::reportMemoryUsage):
3598         * css/StyleRule.h:
3599         (WebCore):
3600         (StyleRuleBase):
3601         (StyleRule):
3602         (StyleRuleFontFace):
3603         (StyleRulePage):
3604         (StyleRuleBlock):
3605         (StyleRuleMedia):
3606         (StyleRuleRegion):
3607         * css/StyleSheetContents.cpp:
3608         (WebCore::StyleSheetContents::reportMemoryUsage):
3609         (WebCore):
3610         * css/StyleSheetContents.h:
3611         (WebCore):
3612         (StyleSheetContents):
3613         * dom/Document.cpp:
3614         (WebCore::Document::reportMemoryUsage):
3615         * dom/MemoryInstrumentation.h:
3616         (WebCore::MemoryClassInfo::addInstrumentedVectorPtr):
3617         (WebCore::MemoryClassInfo::addVectorPtr):
3618
3619 2012-08-01  Keishi Hattori  <keishi@webkit.org>
3620
3621         Attempt to fix flakiness of color-suggestion-picker-appearance.html
3622         https://bugs.webkit.org/show_bug.cgi?id=92848
3623
3624         Reviewed by Kent Tamura.
3625
3626         * Resources/colorSuggestionPicker.js:
3627         (ColorPicker.prototype._layout): We put the width and height into
3628         variables so we don't call window.onresize twice.
3629
3630 2012-08-01  Carlos Garcia Campos  <cgarcia@igalia.com>
3631
3632         Unreviewed. Fix GTK+ build with recent version of GTK+.
3633
3634         Use g_threads_enter/leave instead of the wrapper macros. This
3635         gives a compile warning because they are now deprecated but at
3636         least it builds.
3637
3638         * plugins/gtk/gtk2xtbin.c:
3639         (xt_event_prepare):
3640         (xt_event_check):
3641         (xt_event_dispatch):
3642
3643 2012-08-01  Alexei Filippov  <alexeif@chromium.org>
3644
3645         Web Inspector: Add native memory used by GlyphCache to the snapshot
3646         https://bugs.webkit.org/show_bug.cgi?id=90615
3647
3648         Reviewed by Yury Semikhatsky.
3649
3650         Adds interface for reporting memory usage of platform specific
3651         components.
3652         Report memory usage of the font cache allocated by skia in chromium.
3653
3654         * inspector/InspectorMemoryAgent.cpp:
3655         (WebCore::addPlatformComponentsInfo):
3656         (WebCore):
3657         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
3658         * inspector/front-end/NativeMemorySnapshotView.js:
3659         (WebInspector.MemoryBlockViewProperties._initialize):
3660         * platform/MemoryUsageSupport.cpp:
3661         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
3662         (WebCore):
3663         * platform/MemoryUsageSupport.h:
3664         (MemoryUsageSupport):
3665         (ComponentInfo):
3666         (WebCore::MemoryUsageSupport::ComponentInfo::ComponentInfo):
3667         * platform/chromium/MemoryUsageSupportChromium.cpp:
3668         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
3669         (WebCore):
3670         * platform/qt/MemoryUsageSupportQt.cpp:
3671         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
3672         (WebCore):
3673
3674 2012-08-01  Yoshifumi Inoue  <yosin@chromium.org>
3675
3676         [CSS] Add selectors for multiple fields time input UI.
3677         https://bugs.webkit.org/show_bug.cgi?id=92834
3678
3679         Reviewed by Kent Tamura.
3680
3681         This patch adds new selectors and "height" property to spin button
3682         for multiple fields time input UI.
3683
3684         RenderTextControlSingleLine::layout() sets height of spin button for
3685         input type "number" and other input types using RenderTextControlSingleLine
3686         as renderer object. However, multiple fields time input UI doesn't use
3687         it and needs to set height of spin button.
3688
3689         No new tests. This patch doesn't change behavior.
3690
3691         * css/html.css:
3692         (input::-webkit-datetime-edit): Added.
3693         (input::-webkit-datetime-edit-ampm-field): Added.
3694         (input::-webkit-datetime-edit-hour-field): Added.
3695         (input::-webkit-datetime-edit-millisecond-field): Added.
3696         (input::-webkit-datetime-edit-minute-field): Added.
3697         (input::-webkit-datetime-edit-minute-field[readonly]): Added. This selector
3698         is used for step>=3600 second and time format contains minute field.
3699         (input::-webkit-datetime-edit-second-field): Added.
3700         (input::-webkit-datetime-edit-second-field[readonly]): Added. This selector
3701         is used for step>=60 second and time format contains second field.
3702         (input::-webkit-inner-spin-button): Add "height" property for using
3703         spin button other than RenderTextControlSingleLine.
3704
3705 2012-08-01  Kwang Yul Seo  <skyul@company100.net>
3706
3707         Make HTMLConstructionSite::createHTMLElement(AtomicHTMLToken*) private.
3708         https://bugs.webkit.org/show_bug.cgi?id=92846
3709
3710         Reviewed by Eric Seidel.
3711
3712         This method is internal to HTMLConstructionSite.
3713
3714         No functional change.
3715
3716         * html/parser/HTMLConstructionSite.h:
3717         (HTMLConstructionSite):
3718
3719 2012-08-01  Kinuko Yasuda  <kinuko@chromium.org>
3720
3721         [Filesystem] Assertion on $0.webkitEntries while on the input field.
3722         https://bugs.webkit.org/show_bug.cgi?id=91954
3723
3724         Reviewed by Kent Tamura.
3725
3726         Accessing .webkitEntries should not crash when input type is not for file.
3727
3728         Tests: fast/filesystem/input-access-entries.html
3729
3730         * Modules/filesystem/HTMLInputElementFileSystem.cpp:
3731         (WebCore::HTMLInputElementFileSystem::webkitEntries):
3732
3733 2012-08-01  Eugene Klyuchnikov  <eustas.big@gmail.com>
3734
3735         Web Inspector: Profiles: cleanup HeapSnapshotReceiver interface
3736         https://bugs.webkit.org/show_bug.cgi?id=92390
3737
3738         Reviewed by Yury Semikhatsky.
3739
3740         Remove callback parameter and return values from methods startLoading
3741         and finishLoading. All implementations of HeapSnapshotReceiver honestly
3742         override interface methods now.
3743
3744         * inspector/front-end/HeapSnapshotLoader.js: Adopted new API.
3745         * inspector/front-end/HeapSnapshotProxy.js: Adopted new API. 
3746         (WebInspector.HeapSnapshotLoaderProxy.prototype.isStarted): Added.
3747         (WebInspector.HeapSnapshotLoaderProxy.prototype.addConsumer): Added.
3748         (WebInspector.HeapSnapshotLoaderProxy.prototype.finishLoading):
3749         Explicitly finishes loading and build snapshot.
3750         * inspector/front-end/HeapSnapshotView.js:
3751         (WebInspector.HeapSnapshotReceiver.prototype.startLoading):
3752         Removed callback parameter and return value.
3753         (WebInspector.HeapSnapshotReceiver.prototype.finishLoading):
3754         Removed callback parameter.
3755         (WebInspector.HeapSnapshotSaveToFileReceiver): Adopted new API.
3756
3757 2012-04-07  Ilya Tikhonovsky  <loislo@chromium.org>
3758
3759         Web Inspector: extract MemoryInstrumentationImpl into separate files for future reusing in unit tests
3760         https://bugs.webkit.org/show_bug.cgi?id=92751
3761
3762         Reviewed by Yury Semikhatsky.
3763
3764         * CMakeLists.txt:
3765         * GNUmakefile.list.am:
3766         * Target.pri:
3767         * WebCore.gypi:
3768         * WebCore.vcproj/WebCore.vcproj:
3769         * inspector/InspectorAllInOne.cpp:
3770         * inspector/InspectorMemoryAgent.cpp:
3771         (WebCore):
3772         * inspector/MemoryInstrumentationImpl.cpp: Added.
3773         (WebCore):
3774         (WebCore::MemoryInstrumentationImpl::MemoryInstrumentationImpl):
3775         (WebCore::MemoryInstrumentationImpl::processDeferredInstrumentedPointers):
3776         (WebCore::MemoryInstrumentationImpl::countObjectSize):
3777         (WebCore::MemoryInstrumentationImpl::deferInstrumentedPointer):
3778         (WebCore::MemoryInstrumentationImpl::visited):
3779         (WebCore::MemoryInstrumentationImpl::selfSize):
3780         * inspector/MemoryInstrumentationImpl.h: Added.
3781         (WebCore):
3782         (MemoryInstrumentationImpl):
3783         (WebCore::MemoryInstrumentationImpl::totalTypeSize):
3784
3785 2012-07-31  MORITA Hajime  <morrita@google.com>
3786
3787         Internals::setAuthorShadowDOMForAnyElementEnabled should be on InternalSettings
3788         https://bugs.webkit.org/show_bug.cgi?id=92823
3789
3790         Reviewed by Kentaro Hara.
3791
3792         This change moves Internals::setAuthorShadowDOMForAnyElementEnabled() to
3793         InternalSettings to support original value recovery.
3794
3795         * testing/InternalSettings.cpp:
3796         (WebCore::InternalSettings::Backup::Backup):
3797         (WebCore::InternalSettings::Backup::restoreTo):
3798         (WebCore::InternalSettings::setAuthorShadowDOMForAnyElementEnabled): Moved from Internals.
3799         (WebCore):
3800         * testing/InternalSettings.h:
3801         (Backup):
3802         (InternalSettings):
3803         * testing/InternalSettings.idl:
3804         * testing/Internals.cpp:
3805         * testing/Internals.h:
3806         (Internals):
3807         * testing/Internals.idl:
3808
3809 2012-07-31  Vincent Scheib  <scheib@chromium.org>
3810
3811         webkitRequestPointerLock and webkitExitPointerLock limited to the same document of an active Pointer lock.
3812         https://bugs.webkit.org/show_bug.cgi?id=91284
3813
3814         Reviewed by Adrienne Walker.
3815
3816         Previously, cross-talk between documents was possible, e.g. allowing one
3817         document.webkitExitPointerLock to exit the lock from another document.
3818         This change brings Pointer Lock closer to the Fullscreen API behavior,
3819         and stops the pointer lock target from being transferable between
3820         documents.
3821
3822         Test: http/tests/pointer-lock/requestPointerLock-can-not-transfer-between-documents.html
3823
3824         * dom/Document.cpp:
3825         (WebCore::Document::webkitExitPointerLock):
3826         * page/PointerLockController.cpp:
3827         (WebCore::PointerLockController::requestPointerLock):
3828
3829 2012-07-31  Keishi Hattori  <keishi@webkit.org>
3830
3831         ColorInputType::typeMismatchFor is returning the opposite bool
3832         https://bugs.webkit.org/show_bug.cgi?id=92836
3833
3834         Reviewed by Kent Tamura.
3835
3836         No new tests. Covered by color-suggestion-picker-appearance.html.
3837
3838         * html/ColorInputType.cpp:
3839         (WebCore::ColorInputType::typeMismatchFor):
3840
3841 2012-07-31  Douglas Stockwell  <dstockwell@chromium.org>
3842
3843         -webkit-flex-flow does not work with inherit/initial values
3844         https://bugs.webkit.org/show_bug.cgi?id=92709
3845
3846         Reviewed by Ojan Vafai.
3847
3848         Add a new handler for flex-flow and move flex to StyleBuilder to mirror the standard pattern for handling initial/inherit in shorthands.
3849
3850         Test: css3/flexbox/flex-flow-initial.html
3851
3852         * css/StyleBuilder.cpp:
3853         (WebCore::StyleBuilder::StyleBuilder): Added handlers for flex and flex-flow.
3854         * css/StyleResolver.cpp:
3855         (WebCore::StyleResolver::collectMatchingRulesForList): Removed hand written logic for handling flex.
3856
3857 2012-07-31  Emil A Eklund  <eae@chromium.org>
3858
3859         Float imprecision causes incorrect wrapping in LineLayout with subpixel layout
3860         https://bugs.webkit.org/show_bug.cgi?id=92778
3861
3862         Reviewed by Eric Seidel.
3863
3864         Due to float imprecision an incorrect wrapping decision is made in
3865         certain cases where the values being compare are close but not exactly
3866         the same. This can happen as the size of blocks is represented in layout
3867         units while line layout uses floats.
3868
3869         Test: fast/sub-pixel/inline-block-should-not-wrap.html
3870
3871         * rendering/RenderBlockLineLayout.cpp:
3872         (WebCore::LineWidth::fitsOnLine):
3873         Use LayoutUnit::epsilon when comparing values as that is the maximum
3874         precision we support.
3875
3876 2012-07-31  Hayato Ito  <hayato@chromium.org>
3877
3878         Refactor EventDispatcher::dispatchEvent() so that we can call each phase (Caputure, Target and Bubbling) of event dispatching separately.
3879         https://bugs.webkit.org/show_bug.cgi?id=92621
3880
3881         Reviewed by Dimitri Glazkov.
3882
3883         This is one of the required refactorings to support event
3884         propagation for seamless iframes.  I've removed 'goto' statements
3885         from EventDispatcher::dispatchEvent() as a result.
3886
3887         I've verified that all separated functions are successfully
3888         inlined. I could not see any performance regression.  The
3889         benchmark result is:
3890
3891         Before this patch:
3892         % ./Tools/Scripts/run-perf-tests PerformanceTests/DOM/Events.html
3893         Running 1 tests
3894         Running DOM/Events.html (1 of 1)
3895         RESULT DOM: Events= 243.986607143 ms
3896         median= 242.297619048 ms, stdev= 5.74748351315 ms, min= 239.80952381 ms, max= 268.0 ms
3897
3898         After this patch:
3899         % ./Tools/Scripts/run-perf-tests PerformanceTests/DOM/Events.html
3900         Running 1 tests
3901         Running DOM/Events.html (1 of 1)
3902         RESULT DOM: Events= 242.291666667 ms
3903         median= 240.452380952 ms, stdev= 5.8718643632 ms, min= 238.214285714 ms, max= 266.5 ms
3904
3905         No new tests, no behavior change.
3906
3907         * dom/EventDispatcher.cpp:
3908         (WebCore::EventDispatcher::dispatchEvent):
3909         (WebCore::EventDispatcher::dispatchEventPreProcess):
3910         (WebCore):
3911         (WebCore::EventDispatcher::dispatchEventAtCapturing):
3912         (WebCore::EventDispatcher::dispatchEventAtTarget):
3913         (WebCore::EventDispatcher::dispatchEventAtBubbling):
3914         (WebCore::EventDispatcher::dispatchEventPostProcess):
3915         (WebCore::EventDispatcher::topEventContext):
3916         * dom/EventDispatcher.h:
3917         (WebCore):
3918         (EventDispatcher):
3919
3920 2012-07-31  Yoshifumi Inoue  <yosin@chromium.org>
3921
3922         [Chromium] Enable ENABLE_INPUT_TYPE_TIME_MULTIPLE_FIELDS
3923         https://bugs.webkit.org/show_bug.cgi?id=92822
3924
3925         Reviewed by Kent Tamura.
3926
3927         This patch touches header files for compiling files which contains
3928         ENABLE_INPUT_TYPE_TIME_MULTIPLE_FIELDS.
3929
3930         No new tests. This patch doesn't change behavior.
3931
3932         * platform/text/DateTimeFormat.h:
3933         * platform/text/LocaleICU.h:
3934         * platform/text/LocaleWin.h:
3935         * platform/text/LocalizedDate.h:
3936         * platform/text/LocalizedNumber.h:
3937         * platform/text/mac/LocaleMac.h:
3938
3939 2012-07-30  Ryosuke Niwa  <rniwa@webkit.org>
3940
3941         REGRESSION(r120979): Node list returned by getElementsByTagNameNS isn't invalidated when children changes
3942         https://bugs.webkit.org/show_bug.cgi?id=92705
3943
3944         Reviewed by Abhishek Arya.
3945
3946         The bug was caused by a typo in NodeListsNodeData::invalidateCaches. We need to invalidate
3947         tag name node lists when child nodes change and not when attributes change.
3948
3949         Test: fast/dom/NodeList/nodelist-namespace-invalidation.html
3950
3951         * dom/Node.cpp:
3952         (WebCore::NodeListsNodeData::invalidateCaches):
3953
3954 2012-07-31  Tony Chang  <tony@chromium.org>
3955
3956         flexbox should avoid floats
3957         https://bugs.webkit.org/show_bug.cgi?id=92661
3958
3959         Reviewed by Ojan Vafai.
3960
3961         Block types should avoid floats. Deprecated flexbox and grid already avoid floats.
3962
3963         Tests: css3/flexbox/floated-flexbox.html - added a test case.
3964
3965         * rendering/RenderFlexibleBox.h:
3966
3967 2012-07-31  Tony Chang  <tony@chromium.org>
3968
3969         REGRESSION: flexbox content-size fails to exclude scrollbar
3970         https://bugs.webkit.org/show_bug.cgi?id=92667
3971
3972         Reviewed by Ojan Vafai.
3973
3974         In r123909, we switched to computing the height using computeContentLogicalHeightUsing().
3975         Unfortunately, this includes the scrollbar when we want the content height. Add a helper
3976         method for computing the value needed by flexbox.
3977
3978         Test: css3/flexbox/content-height-with-scrollbars.html
3979
3980         * rendering/RenderFlexibleBox.cpp:
3981         (WebCore::RenderFlexibleBox::mainAxisContentExtent): Use computeLogicalClientHeight
3982         (WebCore::RenderFlexibleBox::computeLogicalClientHeight): Add new method for taking scrollbar into consideration.
3983         (WebCore::RenderFlexibleBox::computeAvailableFreeSpace): Use computeLogicalClientHeight
3984         (WebCore::RenderFlexibleBox::lineBreakLength): Use computeLogicalClientHeight
3985         * rendering/RenderFlexibleBox.h:
3986
3987 2012-07-31  Kwang Yul Seo  <skyul@company100.net>
3988
3989         Remove unused method HTMLElementStack::bottom()
3990         https://bugs.webkit.org/show_bug.cgi?id=92807
3991
3992         Reviewed by Kentaro Hara.
3993
3994         HTMLElementStack::bottom() was replaced with HTMLElementStack::rootNode()
3995         in r80231.
3996
3997         No functional change, so no new tests.
3998
3999         * html/parser/HTMLElementStack.cpp:
4000         * html/parser/HTMLElementStack.h:
4001         (HTMLElementStack):
4002
4003 2012-07-31  Tony Chang  <tony@chromium.org>
4004
4005         -webkit-order should take an integer, not a number
4006         https://bugs.webkit.org/show_bug.cgi?id=92688
4007
4008         Reviewed by Ojan Vafai.
4009
4010         The spec changed back from floats to integers:
4011         http://lists.w3.org/Archives/Public/www-style/2012Jul/0607.html
4012
4013         Tests: css3/flexbox/css-properties.html: Updated.
4014                css3/flexbox/flex-order.html: Test cases modified.
4015
4016
4017         * css/CSSComputedStyleDeclaration.cpp:
4018         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
4019         * css/CSSParser.cpp:
4020         (WebCore::CSSParser::parseValue):
4021         * css/StyleBuilder.cpp:
4022         (WebCore::StyleBuilder::StyleBuilder):
4023         * rendering/RenderFlexibleBox.cpp:
4024         (WebCore):
4025         (RenderFlexibleBox::OrderHashTraits):
4026         (WebCore::RenderFlexibleBox::OrderHashTraits::emptyValue):
4027         (WebCore::RenderFlexibleBox::OrderHashTraits::constructDeletedValue):
4028         (WebCore::RenderFlexibleBox::OrderHashTraits::isDeletedValue):
4029         (RenderFlexibleBox::OrderIterator):
4030         * rendering/RenderFlexibleBox.h:
4031         * rendering/style/RenderStyle.h:
4032         * rendering/style/StyleRareNonInheritedData.h:
4033         (StyleRareNonInheritedData):
4034
4035 2012-07-31  James Robinson  <jamesr@chromium.org>
4036
4037         [chromium] Use skia directly in CCHeadsUpDisplayLayerImpl
4038         https://bugs.webkit.org/show_bug.cgi?id=92810
4039
4040         Reviewed by Adrienne Walker.
4041
4042         The chromium compositor HUD doesn't need to use a full GraphicsContext/etc, all it draws are rectangles and a
4043         simple stroked path. This draws the HUD with straight skia calls and removes the now unnecessary PlatformCanvas
4044         wrapper.
4045
4046         * WebCore.gypi:
4047         * platform/graphics/chromium/PlatformCanvas.cpp: Removed.
4048         * platform/graphics/chromium/PlatformCanvas.h: Removed.
4049         * platform/graphics/chromium/cc/CCFontAtlas.cpp:
4050         (WebCore::CCFontAtlas::drawText):
4051         * platform/graphics/chromium/cc/CCFontAtlas.h:
4052         (CCFontAtlas):
4053         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
4054         (WebCore::CCHeadsUpDisplayLayerImpl::willDraw):
4055         (WebCore::CCHeadsUpDisplayLayerImpl::drawHudContents):
4056         (WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounter):
4057         (WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounterText):
4058         (WebCore::CCHeadsUpDisplayLayerImpl::drawDebugRects):
4059         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.h:
4060         (WebCore):
4061
4062 2012-07-31  Dean Jackson  <dino@apple.com>
4063
4064         ImageCG doesn't initialize m_decodedPropertiesSize in BitmapImage constructor
4065         https://bugs.webkit.org/show_bug.cgi?id=92418
4066
4067         Reviewed by Dan Bernstein.
4068
4069         Tested by existing content.
4070
4071         * platform/graphics/cg/ImageCG.cpp:
4072         (WebCore::BitmapImage::BitmapImage): initialize m_decodedPropertiesSize to zero.
4073
4074 2012-07-31  Shawn Singh  <shawnsingh@chromium.org>
4075
4076         [chromium] Hit test points are being clipped by layers that should not clip
4077         https://bugs.webkit.org/show_bug.cgi?id=92786
4078
4079         Reviewed by James Robinson.
4080
4081         On impl-side hit testing for chromium compositor, we are
4082       &