1 2013-02-05 Eunmi Lee <eunmi15.lee@samsung.com> and Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com>
3 [EFL][WK2] Refactoring initialization and shutdown codes of EFL libraries.
4 https://bugs.webkit.org/show_bug.cgi?id=97173
6 Reviewed by Kenneth Rohde Christiansen, signed-off by Benjamin Poulain.
8 Remove codes to initialize and shutdown the EFL libraries from
9 RunLoopEfl.cpp. Initialization and shutdown will be done in the
10 ewk_main.cpp for ui process and WebProcessMainEfl.cpp for web
13 No new tests. This patch doesn't change behavior.
15 * platform/efl/RunLoopEfl.cpp:
16 (WebCore::RunLoop::RunLoop):
17 (WebCore::RunLoop::~RunLoop):
19 2013-02-07 Ilya Tikhonovsky <loislo@chromium.org>
21 Unreviewed fix for inspector tests in debug.
22 m_frontend should be initialized in constructor.
24 * inspector/InspectorMemoryAgent.cpp:
25 (WebCore::InspectorMemoryAgent::InspectorMemoryAgent):
27 2013-02-07 Yury Semikhatsky <yurys@chromium.org>
29 Web Inspector: reduce number of native memory instrumentation categories
30 https://bugs.webkit.org/show_bug.cgi?id=109146
32 Reviewed by Pavel Feldman.
34 Merged some of memory instrumentation categories.
36 * dom/WebCoreMemoryInstrumentation.cpp:
38 * inspector/front-end/NativeMemorySnapshotView.js:
39 (WebInspector.MemoryBlockViewProperties._initialize):
40 * platform/PlatformMemoryInstrumentation.cpp:
43 2013-02-04 Kentaro Hara <haraken@chromium.org>
45 [V8] Remove V8GCController::m_edenNodes and make minor DOM GC more precise
46 https://bugs.webkit.org/show_bug.cgi?id=108579
48 Reviewed by Adam Barth.
50 Currently V8GCController::m_edenNodes stores a list of nodes whose
51 wrappers have been created since the latest GC. The reason why we
52 needed m_edenNodes is that there was no way to know a list of wrappers
53 in the new space of V8. By using m_edenNodes, we had been approximating
54 'wrappers in the new space' by 'wrappers that have been created since
57 Now V8 provides VisitHandlesForPartialDependence(), with which WebKit
58 can know a list of wrappers in the new space. By using the API, we can
59 remove V8GCController::m_edenNodes. The benefit is that (1) we no longer
60 need to keep m_edenNodes and that (2) it enables more precise minor
61 DOM GC (Remember that m_edenNodes was just an approximation).
63 Performance benchmark: https://bugs.webkit.org/attachment.cgi?id=185940
64 The benchmark runs 300 iterations, each of which creates 100000 elements.
65 The benchmark measures average, min, median, max and stdev of execution times
66 of the 300 iterations. This will tell us the worst-case overhead of this change.
69 mean=59.91ms, min=39ms, median=42ms, max=258ms, stdev=47.48ms
72 mean=58.75ms, min=35ms, median=41ms, max=250ms, stdev=47.32ms
74 As shown above, I couldn't observe any performance regression.
76 No tests. No change in behavior.
78 * bindings/v8/DOMDataStore.h:
79 (WebCore::DOMDataStore::setWrapperInObject):
80 * bindings/v8/DOMWrapperWorld.h:
82 (WebCore::DOMWrapperWorld::getWorldWithoutContextCheck):
83 * bindings/v8/V8Binding.h:
85 (WebCore::worldForEnteredContextIfIsolated):
86 (WebCore::worldForEnteredContextWithoutContextCheck):
87 * bindings/v8/V8DOMWindowShell.cpp:
88 (WebCore::V8DOMWindowShell::initializeIfNeeded):
89 * bindings/v8/V8GCController.cpp:
92 (MinorGCWrapperVisitor):
93 (WebCore::MinorGCWrapperVisitor::MinorGCWrapperVisitor):
94 (WebCore::MinorGCWrapperVisitor::notifyFinished):
95 (WebCore::MajorGCWrapperVisitor::MajorGCWrapperVisitor):
96 (WebCore::V8GCController::gcPrologue):
97 (WebCore::V8GCController::minorGCPrologue):
98 (WebCore::V8GCController::majorGCPrologue):
99 * bindings/v8/V8GCController.h:
102 2013-02-06 Kent Tamura <tkent@chromium.org>
104 REGRESSION(r141195): INPUT_MULTIPLE_FIELDS_UI: Space in a placeholder string is removed
105 https://bugs.webkit.org/show_bug.cgi?id=109132
107 Reviewed by Hajime Morita.
109 <input type=date> should be shown in Japanese UI as:
111 But it is shown wrongly since r141195:
114 We should use white-space:pre.
116 No new tests. This change is not testable in WebKit because this
117 requires a Japanese-localized UI string of Chromium.
120 (input::-webkit-datetime-edit-fields-wrapper):
121 Use white-space:pre instead of nowrap.
123 2013-02-06 Kentaro Hara <haraken@chromium.org>
125 Remove DOMWindow::parseModalDialogFeatures()
126 https://bugs.webkit.org/show_bug.cgi?id=109139
128 Reviewed by Kent Tamura.
130 No one uses the method. FIXME is saying:
132 // FIXME: We can remove this function once V8 showModalDialog is changed to use DOMWindow.
134 Given that V8's showModalDialog() is now using DOMWindow, we can remove it.
136 No tests. No change in behavior.
138 * page/DOMWindow.cpp:
142 2013-02-06 Ilya Tikhonovsky <loislo@chromium.org>
144 Web Inspector: Native Memory Instrumentation: reduce native heap snapshot runtime memory footprint
145 https://bugs.webkit.org/show_bug.cgi?id=108824
147 Reviewed by Yury Semikhatsky.
149 New event was added into Memory domain addNativeSnapshotChunk.
150 The content of HeapGraphSerializer is completely rewritten according to new API.
151 Now it collects strings, nodes, edges and id2id map and pushes when the collected items count exceed a limit.
152 On the frontend side I added new method for the new event and fixed the postprocessing step.
153 MemoryInstrumentation was slightly changed. Now it reports base to real address map only after reporting the node with real address.
155 * inspector/HeapGraphSerializer.cpp:
156 (WebCore::HeapGraphSerializer::HeapGraphSerializer):
157 (WebCore::HeapGraphSerializer::pushUpdateIfNeed):
159 (WebCore::HeapGraphSerializer::pushUpdate):
160 (WebCore::HeapGraphSerializer::reportNode):
161 (WebCore::HeapGraphSerializer::reportNodeImpl):
162 (WebCore::HeapGraphSerializer::reportEdge):
163 (WebCore::HeapGraphSerializer::reportEdgeImpl):
164 (WebCore::HeapGraphSerializer::reportLeaf):
165 (WebCore::HeapGraphSerializer::reportBaseAddress):
166 (WebCore::HeapGraphSerializer::finish):
167 (WebCore::HeapGraphSerializer::reportMemoryUsage):
168 (WebCore::HeapGraphSerializer::addString):
169 (WebCore::HeapGraphSerializer::toNodeId):
170 (WebCore::HeapGraphSerializer::addRootNode):
171 * inspector/HeapGraphSerializer.h:
172 (HeapGraphSerializer):
173 * inspector/Inspector.json:
174 * inspector/InspectorController.cpp:
175 (WebCore::InspectorController::processMemoryDistribution):
176 * inspector/InspectorMemoryAgent.cpp:
177 (WebCore::InspectorMemoryAgent::getProcessMemoryDistributionMap):
179 (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
180 (WebCore::InspectorMemoryAgent::getProcessMemoryDistributionImpl):
181 (WebCore::InspectorMemoryAgent::setFrontend):
182 (WebCore::InspectorMemoryAgent::clearFrontend):
183 * inspector/InspectorMemoryAgent.h:
184 (InspectorMemoryAgent):
185 * inspector/front-end/NativeHeapSnapshot.js:
186 (WebInspector.NativeHeapSnapshot):
187 (WebInspector.NativeHeapSnapshotNode.prototype.classIndex):
188 (WebInspector.NativeHeapSnapshotNode.prototype.id):
189 (WebInspector.NativeHeapSnapshotNode.prototype.name):
190 (WebInspector.NativeHeapSnapshotNode.prototype.serialize):
191 * inspector/front-end/NativeMemorySnapshotView.js:
192 (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
193 (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked):
194 (WebInspector.NativeSnapshotProfileHeader):
195 (WebInspector.NativeSnapshotProfileHeader.prototype.startSnapshotTransfer):
196 (WebInspector.NativeSnapshotProfileHeader.prototype.addNativeSnapshotChunk):
197 (WebInspector.NativeMemoryProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
198 (WebInspector.NativeMemoryProfileType.prototype.buttonClicked):
199 (WebInspector.NativeMemoryBarChart.prototype._updateStats):
200 * inspector/front-end/ProfilesPanel.js:
201 (WebInspector.ProfilesPanel):
202 (WebInspector.MemoryDispatcher):
203 (WebInspector.MemoryDispatcher.prototype.addNativeSnapshotChunk):
205 2013-02-03 Kentaro Hara <haraken@chromium.org>
207 WebKit's focus events are UIEvents (instead of FocusEvent) and thus don't expose .relatedTarget
208 https://bugs.webkit.org/show_bug.cgi?id=76216
210 Reviewed by Eric Seidel.
212 Spec: http://www.w3.org/TR/DOM-Level-3-Events/#events-FocusEvent
214 This patch creates a new FocusEvent class with a relatedTarget attribute.
215 Now when focusin or focusout events are dispatched, a FocusEvent is created with
216 the relatedTarget attribute set accordingly.
218 Test: fast/events/related-target-focusevent.html
221 * DerivedSources.cpp:
222 * DerivedSources.make:
223 * DerivedSources.pri:
224 * GNUmakefile.list.am:
227 * WebCore.xcodeproj/project.pbxproj:
228 * dom/DOMAllInOne.cpp:
230 (WebCore::Event::isFocusEvent):
234 * dom/EventContext.cpp:
235 (WebCore::EventContext::handleLocalEvents):
237 * dom/FocusEvent.h: Added.
240 (WebCore::FocusEvent::create):
241 (WebCore::FocusEvent::relatedTarget):
242 (WebCore::FocusEvent::setRelatedTarget):
243 (WebCore::toFocusEvent):
244 * dom/FocusEvent.idl: Added.
246 (WebCore::Node::dispatchFocusInEvent):
247 (WebCore::Node::dispatchFocusOutEvent):
249 2013-02-06 Kent Tamura <tkent@chromium.org>
251 Fix style of RenderTheme.cpp and RenderThemeChromiumWin.h
252 https://bugs.webkit.org/show_bug.cgi?id=109137
254 Reviewed by Kentaro Hara.
256 No new tests. Just style fix.
258 * rendering/RenderTheme.cpp:
259 (WebCore::RenderTheme::adjustStyle):
260 (WebCore::RenderTheme::paint):
261 (WebCore::RenderTheme::paintBorderOnly):
262 (WebCore::RenderTheme::paintDecorations):
263 (WebCore::RenderTheme::isControlStyled):
264 (WebCore::RenderTheme::adjustButtonStyle):
265 (WebCore::RenderTheme::systemColor):
266 * rendering/RenderThemeChromiumWin.h:
267 (WebCore::ThemeData::ThemeData):
269 (RenderThemeChromiumWin):
270 (WebCore::RenderThemeChromiumWin::RenderThemeChromiumWin):
271 (WebCore::RenderThemeChromiumWin::~RenderThemeChromiumWin):
273 2013-02-06 Kent Tamura <tkent@chromium.org>
275 Fix style of Chrome.h and Page.h
276 https://bugs.webkit.org/show_bug.cgi?id=109138
278 Reviewed by Ryosuke Niwa.
280 No new tests. Just style fixes.
285 (WebCore::Chrome::client):
289 (WebCore::ArenaSize::ArenaSize):
293 (WebCore::Page::theme):
294 (WebCore::Page::canStartMedia):
295 (WebCore::Page::editorClient):
296 (WebCore::Page::plugInClient):
297 (WebCore::Page::mainFrame):
298 (WebCore::Page::groupPtr):
299 (WebCore::Page::incrementSubframeCount):
300 (WebCore::Page::decrementSubframeCount):
301 (WebCore::Page::subframeCount):
302 (WebCore::Page::chrome):
303 (WebCore::Page::dragCaretController):
304 (WebCore::Page::dragController):
305 (WebCore::Page::focusController):
306 (WebCore::Page::contextMenuController):
307 (WebCore::Page::inspectorController):
308 (WebCore::Page::pointerLockController):
309 (WebCore::Page::validationMessageClient):
310 (WebCore::Page::settings):
311 (WebCore::Page::progress):
312 (WebCore::Page::backForward):
313 (WebCore::Page::featureObserver):
314 (WebCore::Page::viewMode):
315 (WebCore::Page::setTabKeyCyclesThroughElements):
316 (WebCore::Page::tabKeyCyclesThroughElements):
317 (WebCore::Page::scheduledRunLoopPairs):
318 (WebCore::Page::defersLoading):
319 (WebCore::Page::mediaVolume):
320 (WebCore::Page::pageScaleFactor):
321 (WebCore::Page::deviceScaleFactor):
322 (WebCore::Page::shouldSuppressScrollbarAnimations):
323 (WebCore::Page::pagination):
324 (WebCore::Page::isOnscreen):
325 (WebCore::Page::scriptedAnimationsSuspended):
326 (WebCore::Page::debugger):
327 (WebCore::Page::hasCustomHTMLTokenizerTimeDelay):
328 (WebCore::Page::customHTMLTokenizerTimeDelay):
329 (WebCore::Page::hasCustomHTMLTokenizerChunkSize):
330 (WebCore::Page::customHTMLTokenizerChunkSize):
331 (WebCore::Page::areMemoryCacheClientCallsEnabled):
332 (WebCore::Page::setEditable):
333 (WebCore::Page::isEditable):
334 (WebCore::Page::displayID):
335 (WebCore::Page::layoutMilestones):
336 (WebCore::Page::setIsPainting):
337 (WebCore::Page::isPainting):
338 (WebCore::Page::alternativeTextClient):
339 (WebCore::Page::checkSubframeCountConsistency):
340 (WebCore::Page::group):
342 2013-02-06 Mike West <mkwst@chromium.org>
344 Entity-header extension headers honored on 304 responses.
345 https://bugs.webkit.org/show_bug.cgi?id=72414
347 Reviewed by Alexey Proskuryakov.
349 This patch ports Chromium's network stack logic governing header
350 updates after resource revalidation. Generally, headers sent with 304
351 responses ought to update the original cached resource's headers.
352 Certain headers should never be sent with 304 responses, and we should
353 ignore them if a misconfigured server sends them anyway.
355 Currently, WebCore ignores all headers prefixed with 'content-'. This
356 patch adds 'x-content-' and 'x-webkit-' to the list, as well as specific
357 headers like 'upgrade', 'trailer', and others that the Chromium network
358 stack currently ignores.
360 The tests verify that those headers with visible effect are correctly
361 handled: 'x-frame-options', 'content-security-policy', and
364 Tests: http/tests/security/XFrameOptions/x-frame-options-cached.html
365 http/tests/security/contentSecurityPolicy/cached-frame-csp.html
366 http/tests/security/xssAuditor/cached-frame.html
368 * loader/cache/CachedResource.cpp:
370 (WebCore::CachedResource::updateResponseAfterRevalidation):
371 This patch adds two arrays containing the specific headers to
372 ignore and the prefixes to ignore. These lists are processed in
373 shouldUpdateHeaderAfterRevalidation.
374 CachedResource::updateResponseAfterRevalidation relies on this new
375 method when processing revalidated resources.
377 * loader/cache/CachedResource.cpp:
379 (WebCore::shouldUpdateHeaderAfterRevalidation):
380 (WebCore::CachedResource::updateResponseAfterRevalidation):
382 2013-02-06 Tom Sepez <tsepez@chromium.org>
384 document.referrer leakage with XSS Auditor page block
385 https://bugs.webkit.org/show_bug.cgi?id=109089
387 Reviewed by Adam Barth.
389 Pass "about:blank" as referrer instead of "" so that the actual page
390 is not leaked when empty referrers are replaced later on in the
393 * html/parser/XSSAuditorDelegate.cpp:
394 (WebCore::XSSAuditorDelegate::didBlockScript):
396 2013-02-06 Kentaro Hara <haraken@chromium.org>
398 [V8] Make an Isolate parameter mandatory in GetTemplate() and GetRawTemplate()
399 https://bugs.webkit.org/show_bug.cgi?id=109026
401 Reviewed by Adam Barth.
403 Now it's time to kill an optional Isolate parameter.
405 No tests. No change in behavior.
407 * bindings/scripts/CodeGeneratorV8.pm:
409 (GenerateNamedConstructorCallback):
410 (GenerateImplementation):
411 * bindings/scripts/test/V8/V8Float64Array.cpp:
412 (WebCore::V8Float64Array::GetRawTemplate):
413 (WebCore::V8Float64Array::GetTemplate):
414 * bindings/scripts/test/V8/V8Float64Array.h:
416 (WebCore::V8Float64Array::installPerContextPrototypeProperties):
417 * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
418 (WebCore::V8TestActiveDOMObject::GetRawTemplate):
419 (WebCore::V8TestActiveDOMObject::GetTemplate):
420 * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
421 (V8TestActiveDOMObject):
422 (WebCore::V8TestActiveDOMObject::installPerContextPrototypeProperties):
423 * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
424 (WebCore::V8TestCustomNamedGetter::GetRawTemplate):
425 (WebCore::V8TestCustomNamedGetter::GetTemplate):
426 * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
427 (V8TestCustomNamedGetter):
428 (WebCore::V8TestCustomNamedGetter::installPerContextPrototypeProperties):
429 * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
430 (WebCore::V8TestEventConstructor::GetRawTemplate):
431 (WebCore::V8TestEventConstructor::GetTemplate):
432 * bindings/scripts/test/V8/V8TestEventConstructor.h:
433 (V8TestEventConstructor):
434 (WebCore::V8TestEventConstructor::installPerContextPrototypeProperties):
435 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
436 (WebCore::V8TestEventTarget::GetRawTemplate):
437 (WebCore::V8TestEventTarget::GetTemplate):
438 * bindings/scripts/test/V8/V8TestEventTarget.h:
440 (WebCore::V8TestEventTarget::installPerContextPrototypeProperties):
441 * bindings/scripts/test/V8/V8TestException.cpp:
442 (WebCore::V8TestException::GetRawTemplate):
443 (WebCore::V8TestException::GetTemplate):
444 * bindings/scripts/test/V8/V8TestException.h:
446 (WebCore::V8TestException::installPerContextPrototypeProperties):
447 * bindings/scripts/test/V8/V8TestInterface.cpp:
448 (WebCore::V8TestInterface::GetRawTemplate):
449 (WebCore::V8TestInterface::GetTemplate):
450 * bindings/scripts/test/V8/V8TestInterface.h:
452 (WebCore::V8TestInterface::installPerContextPrototypeProperties):
453 * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
454 (WebCore::V8TestMediaQueryListListener::GetRawTemplate):
455 (WebCore::V8TestMediaQueryListListener::GetTemplate):
456 * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
457 (V8TestMediaQueryListListener):
458 (WebCore::V8TestMediaQueryListListener::installPerContextPrototypeProperties):
459 * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
460 (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
461 (WebCore::V8TestNamedConstructor::GetRawTemplate):
462 (WebCore::V8TestNamedConstructor::GetTemplate):
463 * bindings/scripts/test/V8/V8TestNamedConstructor.h:
464 (V8TestNamedConstructor):
465 (WebCore::V8TestNamedConstructor::installPerContextPrototypeProperties):
466 * bindings/scripts/test/V8/V8TestNode.cpp:
467 (WebCore::V8TestNode::GetRawTemplate):
468 (WebCore::V8TestNode::GetTemplate):
469 * bindings/scripts/test/V8/V8TestNode.h:
471 (WebCore::V8TestNode::installPerContextPrototypeProperties):
472 * bindings/scripts/test/V8/V8TestObj.cpp:
473 (WebCore::V8TestObj::GetRawTemplate):
474 (WebCore::V8TestObj::GetTemplate):
475 (WebCore::V8TestObj::installPerContextPrototypeProperties):
476 * bindings/scripts/test/V8/V8TestObj.h:
478 * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
479 (WebCore::V8TestOverloadedConstructors::GetRawTemplate):
480 (WebCore::V8TestOverloadedConstructors::GetTemplate):
481 * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
482 (V8TestOverloadedConstructors):
483 (WebCore::V8TestOverloadedConstructors::installPerContextPrototypeProperties):
484 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
485 (WebCore::V8TestSerializedScriptValueInterface::GetRawTemplate):
486 (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
487 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
488 (V8TestSerializedScriptValueInterface):
489 (WebCore::V8TestSerializedScriptValueInterface::installPerContextPrototypeProperties):
490 * bindings/v8/V8PerContextData.cpp:
491 (WebCore::V8PerContextData::constructorForTypeSlowCase):
492 * bindings/v8/WrapperTypeInfo.h:
494 (WebCore::WrapperTypeInfo::installPerContextPrototypeProperties):
496 2013-02-06 Terry Anderson <tdanderson@chromium.org>
498 Add support for gesture scroll events that do not propagate to enclosing scrollables
499 https://bugs.webkit.org/show_bug.cgi?id=108849
501 Reviewed by Antonio Gomes.
503 Tests: fast/events/touch/gesture/touch-gesture-scroll-div-not-propagated.html
504 fast/events/touch/gesture/touch-gesture-scroll-iframe-not-propagated.html
505 fast/events/touch/gesture/touch-gesture-scroll-page-not-propagated.html
507 Rename RenderLayer::scrollByRecursively() to RenderLayer::scrollBy() and add a parameter
508 of type RenderLayer::ScrollPropagation to specify whether or not the scroll should
509 propagate to its parent by recursing. Implement RenderLayer::scrollByRecursively() as a
510 call to RenderLayer::scrollBy() with argument RenderLayer::ShouldPropagateScroll so
511 that all existing calls to the function still produce the correct behavior.
513 In EventHandler::handleGestureScrollUpdate(), call RenderLayer::scrollBy() with
514 argument RenderLayer::ShouldPropagateScroll if |gestureEvent| is a GestureScrollUpdate
515 or instead with argument RenderLayer::DontPropagateScroll if |gestureEvent| is a
516 GestureScrollUpdateWithoutPropagation.
518 * dom/GestureEvent.cpp:
519 (WebCore::GestureEvent::create):
520 * page/EventHandler.cpp:
521 (WebCore::EventHandler::handleGestureEvent):
522 (WebCore::EventHandler::handleGestureScrollUpdate):
523 * platform/PlatformEvent.h:
524 * platform/Scrollbar.cpp:
525 (WebCore::Scrollbar::gestureEvent):
526 * platform/chromium/PopupContainer.cpp:
527 (WebCore::PopupContainer::handleGestureEvent):
528 * rendering/RenderLayer.cpp:
529 (WebCore::RenderLayer::scrollByRecursively):
531 (WebCore::RenderLayer::scrollBy):
532 * rendering/RenderLayer.h:
534 2013-02-06 Ojan Vafai <ojan@chromium.org>
536 [Chromium] table-section-overflow-clip-crash.html hits an assert
537 https://bugs.webkit.org/show_bug.cgi?id=108594
539 Reviewed by Levi Weintraub.
541 When a counter calls setNeedsLayout, it also marks it's containing blocks
542 as needing layout, so we need to clear the setNeedsLayoutIsForbidden bit on the
543 containing blocks as well as the counter itself.
545 Also, use RAII objects for all the places where we clear this bit and make
546 the setter/getter for it private to RenderObject.
548 * rendering/RenderCounter.cpp:
549 (WebCore::RenderCounter::computePreferredLogicalWidths):
550 * rendering/RenderObject.cpp:
551 (WebCore::RenderObject::SetLayoutNeededForbiddenScope::SetLayoutNeededForbiddenScope):
552 (WebCore::RenderObject::markContainingBlocksForLayout):
553 * rendering/RenderObject.h:
554 (SetLayoutNeededForbiddenScope):
556 (WebCore::RenderObject::isSetNeedsLayoutForbidden):
557 (WebCore::RenderObject::setNeedsLayoutIsForbidden):
558 * rendering/RenderQuote.cpp:
559 (WebCore::RenderQuote::computePreferredLogicalWidths):
560 * rendering/RenderTableSection.cpp:
561 (WebCore::RenderTableSection::calcRowLogicalHeight):
562 (WebCore::RenderTableSection::layoutRows):
563 * rendering/mathml/RenderMathMLOperator.cpp:
564 (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
565 * rendering/mathml/RenderMathMLRoot.cpp:
566 (WebCore::RenderMathMLRoot::computePreferredLogicalWidths):
567 * rendering/mathml/RenderMathMLRow.cpp:
568 (WebCore::RenderMathMLRow::computePreferredLogicalWidths):
570 2013-02-06 Ojan Vafai <ojan@chromium.org>
572 display:none file upload button crashes
573 https://bugs.webkit.org/show_bug.cgi?id=109102
575 Reviewed by Levi Weintraub.
577 Test: fast/forms/file/display-none-upload-button.html
579 * rendering/RenderFileUploadControl.cpp:
580 (WebCore::nodeWidth):
581 (WebCore::RenderFileUploadControl::paintObject):
582 Having an upload button doesn't mean we have a rendered upload button.
583 Null check the renderer before trying to access it.
585 2013-02-06 Dirk Schulze <dschulze@adobe.com>
587 Context's currentPath should check for passed type
588 https://bugs.webkit.org/show_bug.cgi?id=109097
590 Reviewed by Dean Jackson.
592 Add check for passed pointer and return earlier.
594 Test: fast/canvas/canvas-currentPath-crash.html
596 * html/canvas/CanvasRenderingContext2D.cpp:
597 (WebCore::CanvasRenderingContext2D::setCurrentPath):
599 2013-02-06 Rafael Weinstein <rafaelw@chromium.org>
601 [HTMLTemplateElement] Non </template> end tags should be ignored in "template contents" insertion mode.
602 https://bugs.webkit.org/show_bug.cgi?id=109090
604 Reviewed by Adam Barth.
606 https://dvcs.w3.org/hg/webcomponents/raw-file/38536d37fb82/spec/templates/index.html#template-contents-insertion-mode.
608 Test added to html5lib suite.
610 * html/parser/HTMLTreeBuilder.cpp:
611 (WebCore::HTMLTreeBuilder::processEndTag):
613 2013-02-06 Alexandre Elias <aelias@chromium.org>
615 Make ScrollView::paint() clip by visibleContentRect
616 https://bugs.webkit.org/show_bug.cgi?id=108888
618 Reviewed by Levi Weintraub.
620 When applyPageScaleFactorInCompositor or fixedVisibleContentRect
621 are used, frameRect() and visibleContentRect(true).size() are
622 no longer synonyms, and the latter is the one that should be
623 used for clipping paints.
625 New WebFrameTest: pageScaleFactorScalesPaintClip.
627 * platform/ScrollView.cpp:
628 (WebCore::ScrollView::paint):
630 2013-02-06 Dima Gorbik <dgorbik@apple.com>
632 Store the language internally instead of using lang attribute for WebVTT nodes
633 https://bugs.webkit.org/show_bug.cgi?id=108858
635 Reviewed by Eric Carlson.
637 Only language webvtt elements should have a lang attribute so we have to store
638 the language internally in the element. Refactored the code to make
639 computeInheritedLanguage virtual.
641 Existing tests were modified to cover this case.
643 * css/SelectorChecker.cpp:
644 (WebCore::SelectorChecker::checkOne):
645 * html/track/WebVTTElement.cpp:
646 (WebCore::WebVTTElement::WebVTTElement):
647 (WebCore::WebVTTElement::cloneElementWithoutAttributesAndChildren):
648 (WebCore::WebVTTElement::createEquivalentHTMLElement): clone the internal language property.
649 * html/track/WebVTTElement.h:
650 (WebCore::WebVTTElement::language):
651 (WebCore::WebVTTElement::setLanguage):
652 * html/track/WebVTTParser.cpp: only set the lang attribute for language objects.
653 (WebCore::WebVTTParser::constructTreeFromToken):
655 2013-02-06 Levi Weintraub <leviw@chromium.org>
657 Negative text indents can break RenderBlock's inline maximum preferred width calculation
658 https://bugs.webkit.org/show_bug.cgi?id=108973
660 Reviewed by Emil A Eklund.
662 Change two quirks about to how we calculate a block's inline preferred width with
665 First, re-use text-indent that's first applied to floats on text that follows it.
666 This matches Layout, as otherwise we can prematurely wrap text when there's a negative
667 margin on a block starting with a float. This also matches FireFox.
669 Second, correct how the max preferred width is calculated in the presence of a negative
670 text-indent. If the text-indent is more negative than the first text line break, we
671 update the value to be the remainder. Previously, we added this remaining negative value
672 to subsequent minimum and maximum preferred width calculations (until the remainder was
673 gone). This is wrong for the max preferred width, as we're adding the negative value more
674 than once, and leads to a max preferred width that's smaller than our line.
676 Test: fast/css/negative-text-indent-in-inline-block.html
678 * rendering/RenderBlock.cpp:
679 (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
681 2013-02-06 Mark Lam <mark.lam@apple.com>
683 Fix broken release builds, greening the bots.
684 https://bugs.webkit.org/show_bug.cgi?id=107475.
690 * Modules/webdatabase/DatabaseManager.cpp:
691 (WebCore::logOpenDatabaseError):
693 2013-02-06 Sheriff Bot <webkit.review.bot@gmail.com>
695 Unreviewed, rolling out r142025.
696 http://trac.webkit.org/changeset/142025
697 https://bugs.webkit.org/show_bug.cgi?id=109091
699 broke the build (Requested by tdanderson on #webkit).
701 * dom/GestureEvent.cpp:
702 (WebCore::GestureEvent::create):
703 * page/EventHandler.cpp:
704 (WebCore::EventHandler::handleGestureEvent):
705 (WebCore::EventHandler::handleGestureScrollUpdate):
706 * platform/PlatformEvent.h:
707 * platform/Scrollbar.cpp:
708 (WebCore::Scrollbar::gestureEvent):
709 * platform/chromium/PopupContainer.cpp:
710 (WebCore::PopupContainer::handleGestureEvent):
711 * rendering/RenderLayer.cpp:
712 (WebCore::RenderLayer::scrollByRecursively):
713 * rendering/RenderLayer.h:
715 2013-02-06 Mark Lam <mark.lam@apple.com>
717 Split openDatabase() between front and back end work.
718 https://bugs.webkit.org/show_bug.cgi?id=107475.
720 Reviewed by Anders Carlsson.
722 The main work of splitting DatabaseManager::openDatabase() is in
723 refactoring how DatabaseTracker::canEstablishDatabase() works. It used
724 to check for adequate space quota, and if the check fails, it would call
725 back into the client from inside canEstablishDatabase(). The call back
726 allows the client to update the quota (if appropriate). Thereafter,
727 canEstablishDatabase() will retry its quota check.
729 In a webkit2 world, we'll want to minimize the traffic between the
730 client (script side) and the server (sqlite db side), and ideally, we
731 don't want the server to call back to the client. Note: the
732 DatabaseTracker belongs on the server side.
734 To achieve this, we split canEstablishDatabase() into 2 parts: the
735 checks before the call back to the client, and the checks after.
736 The first part will retain the name canEstablishDatabase(), and the
737 second part will be named retryCanEstablishDatabase().
738 We also added a DatabaseServer::openDatabase() function that can be
739 called with a retry flag.
741 The client side DatabaseManager::openDatabase() will call
742 DatabaseServer::openDatabase(), which then calls canEstablishDatabase()
743 to do its quota check. If there is enough quota,
744 DatabaseServer::openDatabase() will proceed to open the backend database
745 without return to the client first. The opened database will be returned
748 If DatabaseServer::openDatabase() finds inadequate quota the first time,
749 it will return with a DatabaseSizeExceededQuota error. The DatabaseManager
750 (on the client side) will check for this error and call back to its client
751 for an opportunity to increase the quota. Thereafter, the DatabaseManager
752 will call DatabaseServer::openDatabase() again. This time,
753 DatabaseServer::openDatabase() will call retryCanEstablishDatabase() to
754 check the quota, and then open the backend database if there is enough
759 * Modules/webdatabase/AbstractDatabaseServer.h:
760 * Modules/webdatabase/DOMWindowWebDatabase.cpp:
761 (WebCore::DOMWindowWebDatabase::openDatabase):
762 * Modules/webdatabase/Database.cpp:
763 (WebCore::Database::create):
764 * Modules/webdatabase/Database.h:
766 * Modules/webdatabase/DatabaseBackend.cpp:
767 (WebCore::DatabaseBackend::performOpenAndVerify):
768 * Modules/webdatabase/DatabaseBackend.h:
770 * Modules/webdatabase/DatabaseBackendAsync.cpp:
771 (WebCore::DatabaseBackendAsync::openAndVerifyVersion):
772 (WebCore::DatabaseBackendAsync::performOpenAndVerify):
773 * Modules/webdatabase/DatabaseBackendAsync.h:
774 (DatabaseBackendAsync):
775 * Modules/webdatabase/DatabaseBackendSync.cpp:
776 (WebCore::DatabaseBackendSync::openAndVerifyVersion):
777 * Modules/webdatabase/DatabaseBackendSync.h:
778 (DatabaseBackendSync):
779 * Modules/webdatabase/DatabaseError.h:
780 (WebCore::ENUM_CLASS):
781 * Modules/webdatabase/DatabaseManager.cpp:
782 (WebCore::DatabaseManager::exceptionCodeForDatabaseError):
783 (WebCore::DatabaseManager::openDatabaseBackend):
784 (WebCore::DatabaseManager::openDatabase):
785 (WebCore::DatabaseManager::openDatabaseSync):
786 * Modules/webdatabase/DatabaseManager.h:
788 * Modules/webdatabase/DatabaseServer.cpp:
789 (WebCore::DatabaseServer::openDatabase):
790 (WebCore::DatabaseServer::createDatabase):
791 * Modules/webdatabase/DatabaseServer.h:
792 * Modules/webdatabase/DatabaseSync.cpp:
793 (WebCore::DatabaseSync::create):
794 * Modules/webdatabase/DatabaseSync.h:
796 * Modules/webdatabase/DatabaseTracker.cpp:
797 (WebCore::DatabaseTracker::hasAdequateQuotaForOrigin):
798 (WebCore::DatabaseTracker::canEstablishDatabase):
799 (WebCore::DatabaseTracker::retryCanEstablishDatabase):
800 * Modules/webdatabase/DatabaseTracker.h:
802 * Modules/webdatabase/WorkerContextWebDatabase.cpp:
803 (WebCore::WorkerContextWebDatabase::openDatabase):
804 (WebCore::WorkerContextWebDatabase::openDatabaseSync):
805 * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
806 (WebCore::DatabaseTracker::canEstablishDatabase):
807 (WebCore::DatabaseTracker::retryCanEstablishDatabase):
809 2013-02-06 Tony Gentilcore <tonyg@chromium.org>
811 Fix CompactHTMLToken's copy ctor to copy all fields
812 https://bugs.webkit.org/show_bug.cgi?id=109076
814 Reviewed by Adam Barth.
816 This was introduced by me in r142004. Without this patch we fail all tests when using the background parser.
818 Also don't use getters in copy ctor.
820 No new tests because no new functionality.
822 * html/parser/CompactHTMLToken.cpp:
823 (WebCore::CompactHTMLToken::CompactHTMLToken):
825 2013-02-06 Brian Salomon <bsalomon@google.com>
827 [Chromium/Skia] Remove use of deprecated Skia names
828 https://bugs.webkit.org/show_bug.cgi?id=109085
830 Reviewed by Stephen White.
832 Tested by every existing canvas2d test.
834 * platform/chromium/support/GraphicsContext3DPrivate.cpp:
835 (WebCore::GraphicsContext3DPrivate::grContext):
837 2013-02-06 Terry Anderson <tdanderson@chromium.org>
839 Add support for gesture scroll events that do not propagate to enclosing scrollables
840 https://bugs.webkit.org/show_bug.cgi?id=108849
842 Reviewed by Antonio Gomes.
844 Tests: fast/events/touch/gesture/touch-gesture-scroll-div-not-propagated.html
845 fast/events/touch/gesture/touch-gesture-scroll-iframe-not-propagated.html
846 fast/events/touch/gesture/touch-gesture-scroll-page-not-propagated.html
848 Rename RenderLayer::scrollByRecursively() to RenderLayer::scrollBy() and add a parameter
849 of type RenderLayer::ScrollPropagation to specify whether or not the scroll should
850 propagate to its parent by recursing. Implement RenderLayer::scrollByRecursively() as a
851 call to RenderLayer::scrollBy() with argument RenderLayer::ShouldPropagateScroll so
852 that all existing calls to the function still produce the correct behavior.
854 In EventHandler::handleGestureScrollUpdate(), call RenderLayer::scrollBy() with
855 argument RenderLayer::ShouldPropagateScroll if |gestureEvent| is a GestureScrollUpdate
856 or instead with argument RenderLayer::DontPropagateScroll if |gestureEvent| is a
857 GestureScrollUpdateWithoutPropagation.
859 * dom/GestureEvent.cpp:
860 (WebCore::GestureEvent::create):
861 * page/EventHandler.cpp:
862 (WebCore::EventHandler::handleGestureEvent):
863 (WebCore::EventHandler::handleGestureScrollUpdate):
864 * platform/PlatformEvent.h:
865 * platform/Scrollbar.cpp:
866 (WebCore::Scrollbar::gestureEvent):
867 * platform/chromium/PopupContainer.cpp:
868 (WebCore::PopupContainer::handleGestureEvent):
869 * rendering/RenderLayer.cpp:
870 (WebCore::RenderLayer::scrollByRecursively):
872 (WebCore::RenderLayer::scrollBy):
873 * rendering/RenderLayer.h:
875 2013-02-06 Ryosuke Niwa <rniwa@webkit.org>
877 REGRESSION(r141136): Apple's internal PLT test suite doesn't finish
878 https://bugs.webkit.org/show_bug.cgi?id=108380
880 Reviewed by Alexey Proskuryakov.
882 Re-enable the main resource cache since the regression had been fixed in r141615.
884 * loader/cache/CachedResourceLoader.cpp:
885 (WebCore::CachedResourceLoader::requestResource):
887 2013-02-06 Uday Kiran <udaykiran@motorola.com>
889 Implement 'vmax' from CSS3 values and units
890 https://bugs.webkit.org/show_bug.cgi?id=91440
892 Reviewed by Antti Koivisto.
894 vmax is implemented as primitive length unit.
895 New length type ViewportPercentageMax is added and included support for fetching the value
896 of this viewport percentage unit based on current viewport size.
898 The specification related to this implementation is
899 http://dev.w3.org/csswg/css3-values/#viewport-relative-lengths.
901 Tests: css3/viewport-percentage-lengths/css3-viewport-percentage-lengths-vmax-absolute.html
902 css3/viewport-percentage-lengths/css3-viewport-percentage-lengths-vmax.html
904 * css/CSSGrammar.y.in: Added vmax support.
905 * css/CSSParser.cpp: Parsing of vmax unit.
906 (WebCore::CSSParser::validUnit): Added vmax to valid units.
907 (WebCore::CSSParser::createPrimitiveNumericValue): Added vmax to primitive untis.
908 (WebCore::CSSParser::parseValidPrimitive): Creation of CSSPrimitive for vmax.
909 (WebCore::CSSParser::detectNumberToken): Parsing of vmax token.
910 * css/CSSParserValues.cpp:
911 (WebCore::CSSParserValue::createCSSValue): Added support for vmax.
912 * css/CSSPrimitiveValue.cpp:
913 (WebCore::isValidCSSUnitTypeForDoubleConversion): Added support for vmax.
914 (WebCore::unitCategory): Ditto.
915 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Ditto.
916 (WebCore::CSSPrimitiveValue::cleanup):
917 (WebCore::CSSPrimitiveValue::customCssText): Added support for vmax.
918 (WebCore::CSSPrimitiveValue::viewportPercentageLength): Function to create the Length structure for the viewport-percentage unit types.
919 (WebCore::CSSPrimitiveValue::cloneForCSSOM):
920 * css/CSSPrimitiveValue.h:
921 (WebCore::CSSPrimitiveValue::isViewportPercentageLength): Checks whether the primitive value is ViewportPercentage Length.
922 * css/CSSPrimitiveValue.idl: Added support for vmax.
923 * css/LengthFunctions.cpp: Calcuation of length value based on the current viewport size.
924 (WebCore::minimumValueForLength):
925 (WebCore::valueForLength):
926 (WebCore::floatValueForLength):
928 (WebCore::Length::isViewportPercentage): To check the Length is of type ViewportPercentage.
929 * rendering/RenderBox.cpp:
930 (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
931 (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
933 2013-02-06 Pravin D <pravind.2k4@gmail.com>
935 When a block element is made inline positioned and has static left and right, it does not follow inline formatting context
936 https://bugs.webkit.org/show_bug.cgi?id=91665
938 Reviewed by Julien Chaffraix.
940 Out-of-flow-positioned elements have their display overriden to BLOCK. When a static block elements
941 changes to inline out-of-flow-positioned or vice-versa, the element current and previous display properties
942 are same. This causes the element to follow a wrong flow context(in this case Block context) and the element
943 is laid out incorrectly. The patch fixes the issue by reattaching the renderers of the node whenever either
944 position property changes or when its floating property changes.
945 Also the cases when an out-of-flow-positioned/floating element changes to static/non-floating element where
946 being specially handled. As reattaching the renderers in the above cases correctly handles the above cases,
947 special handling for such cases is no more required and the related code can be safely removed.
949 Reattaching renderers for the afore mentioned issues takes a different(longer) code path. Performance measurements
950 summary for the same is as follows:
952 Absolute-block-to-static-block 2.00
953 Absolute-inline-to-static-block 1.21
954 Absolute-inline-to-static-inline 1.18
955 Static-block-to-absolute-block 1.13
956 Static-inline-to-absolute-inline 1.35
957 Floating-block-non-floating-block 0.85
958 Floating-inline-non-floating-block 0.66
959 Floating-inline-non-floating-inline 0.57
960 Non-floating-block-floating-block 0.12
961 Non-floating-inline-floating-inline 1.36
963 Tests: fast/dynamic/absolute-positioned-to-static-positioned.html
964 fast/dynamic/floating-to-non-floating.html
965 fast/dynamic/non-floating-to-floating.html
966 fast/dynamic/static-positioned-to-absolute-positioned.html
969 (WebCore::Node::diff):
970 Return detach in the following conditions:
971 1) Element changes to out-of-flow-positioned or vice-versa.
972 2) Element becomes floating or vice-versa.
974 * rendering/RenderBlock.cpp:
976 * rendering/RenderBlock.h:
978 * rendering/RenderBoxModelObject.h:
979 (RenderBoxModelObject):
980 * rendering/RenderInline.cpp:
982 * rendering/RenderInline.h:
984 * rendering/RenderObject.cpp:
986 (WebCore::RenderObject::styleWillChange):
987 (WebCore::RenderObject::styleDidChange):
988 * rendering/RenderObject.h:
990 The fix in Node::diff() obsoletes some code. The above deletion are part of this dead code cleanup.
992 2013-02-06 Chris Fleizach <cfleizach@apple.com>
994 AX: if <html> has an ARIA attribute, it's exposed as an AXGroup
995 https://bugs.webkit.org/show_bug.cgi?id=109008
997 Reviewed by Ryosuke Niwa.
999 If an <html> element had an ARIA attribute, it was being turned into an element
1000 in the AX hierarchy. This was causing trouble for screen readers by inserting
1001 an unexpected element in the navigation sequence.
1003 Test: accessibility/html-html-element-is-ignored.html
1005 * accessibility/AccessibilityRenderObject.cpp:
1006 (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
1008 2013-02-06 Shawn Singh <shawnsingh@chromium.org>
1010 RenderLayer hasVisibleContent() has inconsistent semantics causing disappearing composited layers
1011 https://bugs.webkit.org/show_bug.cgi?id=108118
1013 Reviewed by Simon Fraser.
1015 RenderLayerBacking::hasVisibleNonCompositingDescendantLayers was
1016 only checking whether direct children had visible content. As a
1017 result, composited layers had wrong visibility status if only a
1018 deeper descendant RenderLayer was visible.
1020 Test: compositing/visibility/visibility-on-distant-descendant.html
1022 * rendering/RenderLayerBacking.cpp:
1023 (WebCore::hasVisibleNonCompositingDescendant): copied the original
1024 implementation into this function; then added the RenderLayer
1025 recursion as appropriate.
1027 (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers):
1028 This is now just a wrapper to the private static recursive
1031 2013-02-06 Jonathon Jongsma <jonathon.jongsma@collabora.com>
1033 [GStreamer] MediaPlayer's code is not easily reusable by other GStreamer-based players
1034 https://bugs.webkit.org/show_bug.cgi?id=100261
1036 Refactor the media player implementation so that more of the
1037 internal functionality can be shared between the current media
1038 backend and the mediastream player backend. Common code is
1039 broken out into a MediaPlayerPrivateGStreamerBase class, and
1040 both MediaPlayerPrivateGStreamer and
1041 StreamMediaPlayerPrivateGStreamer inherit from this base class.
1043 Reviewed by Philippe Normand
1045 No new tests since functionality is covered by existing media tests
1047 * GNUmakefile.list.am:
1048 * PlatformEfl.cmake:
1050 * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.cpp:
1051 (WebCore::FullscreenVideoControllerGStreamer::create):
1052 (WebCore::FullscreenVideoControllerGStreamer::FullscreenVideoControllerGStreamer):
1053 * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.h:
1055 (FullscreenVideoControllerGStreamer):
1056 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1057 (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
1058 (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
1059 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
1060 (MediaPlayerPrivateGStreamer):
1061 (WebCore::MediaPlayerPrivateGStreamer::isLiveStream):
1062 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: Added.
1064 (WebCore::greatestCommonDivisor):
1065 (WebCore::mediaPlayerPrivateVolumeChangedCallback):
1066 (WebCore::mediaPlayerPrivateVolumeChangeTimeoutCallback):
1067 (WebCore::mediaPlayerPrivateMuteChangedCallback):
1068 (WebCore::mediaPlayerPrivateMuteChangeTimeoutCallback):
1069 (WebCore::mediaPlayerPrivateRepaintCallback):
1070 (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
1071 (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
1072 (WebCore::MediaPlayerPrivateGStreamerBase::naturalSize):
1073 (WebCore::MediaPlayerPrivateGStreamerBase::setVolume):
1074 (WebCore::MediaPlayerPrivateGStreamerBase::volume):
1075 (WebCore::MediaPlayerPrivateGStreamerBase::notifyPlayerOfVolumeChange):
1076 (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
1077 (WebCore::MediaPlayerPrivateGStreamerBase::networkState):
1078 (WebCore::MediaPlayerPrivateGStreamerBase::readyState):
1079 (WebCore::MediaPlayerPrivateGStreamerBase::sizeChanged):
1080 (WebCore::MediaPlayerPrivateGStreamerBase::setMuted):
1081 (WebCore::MediaPlayerPrivateGStreamerBase::muted):
1082 (WebCore::MediaPlayerPrivateGStreamerBase::notifyPlayerOfMute):
1083 (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
1084 (WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
1085 (WebCore::MediaPlayerPrivateGStreamerBase::setSize):
1086 (WebCore::MediaPlayerPrivateGStreamerBase::paint):
1087 (WebCore::MediaPlayerPrivateGStreamerBase::enterFullscreen):
1088 (WebCore::MediaPlayerPrivateGStreamerBase::exitFullscreen):
1089 (WebCore::MediaPlayerPrivateGStreamerBase::supportsFullscreen):
1090 (WebCore::MediaPlayerPrivateGStreamerBase::platformMedia):
1091 (WebCore::MediaPlayerPrivateGStreamerBase::movieLoadType):
1092 (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink):
1093 (WebCore::MediaPlayerPrivateGStreamerBase::setStreamVolumeElement):
1094 (WebCore::MediaPlayerPrivateGStreamerBase::decodedFrameCount):
1095 (WebCore::MediaPlayerPrivateGStreamerBase::droppedFrameCount):
1096 (WebCore::MediaPlayerPrivateGStreamerBase::audioDecodedByteCount):
1097 (WebCore::MediaPlayerPrivateGStreamerBase::videoDecodedByteCount):
1098 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: Added.
1100 (MediaPlayerPrivateGStreamerBase):
1101 (WebCore::MediaPlayerPrivateGStreamerBase::supportsMuting):
1102 (WebCore::MediaPlayerPrivateGStreamerBase::setVisible):
1103 (WebCore::MediaPlayerPrivateGStreamerBase::hasSingleSecurityOrigin):
1104 (WebCore::MediaPlayerPrivateGStreamerBase::maxTimeLoaded):
1105 (WebCore::MediaPlayerPrivateGStreamerBase::canEnterFullscreen):
1106 (WebCore::MediaPlayerPrivateGStreamerBase::mediaPlayer):
1107 (WebCore::MediaPlayerPrivateGStreamerBase::audioSink):
1108 * platform/graphics/gtk/FullscreenVideoControllerGtk.cpp:
1109 (WebCore::FullscreenVideoControllerGtk::FullscreenVideoControllerGtk):
1110 * platform/graphics/gtk/FullscreenVideoControllerGtk.h:
1111 (FullscreenVideoControllerGtk):
1113 2013-02-06 Tony Gentilcore <tonyg@chromium.org>
1115 Call XSSAuditor's didBlockScript() for the threaded HTML parser
1116 https://bugs.webkit.org/show_bug.cgi?id=108726
1118 Reviewed by Adam Barth.
1120 This patch causes us to call didBlockScript() on the main thread if the CompactHTML token has XSSInfo.
1122 1. Rename DidBlockScriptRequest to XSSInfo.
1123 2. Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
1124 3. Add an isSafeToSendToAnotherThread() method to String and KURL.
1126 We don't yet populate didBlockScriptRequest on the background thread, but this should just work once we do.
1128 No new tests because no new functionality.
1130 * html/parser/BackgroundHTMLParser.cpp:
1131 (WebCore::BackgroundHTMLParser::pumpTokenizer): Update comment for rename.
1132 * html/parser/CompactHTMLToken.cpp:
1133 (SameSizeAsCompactHTMLToken):
1134 (WebCore::CompactHTMLToken::CompactHTMLToken): Add a copy constructor used by Vector.
1135 (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread): Include new m_xssInfo field in safety check.
1137 (WebCore::CompactHTMLToken::xssInfo): Added.
1138 (WebCore::CompactHTMLToken::setXSSInfo): Added.
1139 * html/parser/CompactHTMLToken.h: Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
1142 (WTF): Add VectorTraits necessary for copying Vector fields objects that contain an OwnPtr.
1143 * html/parser/HTMLDocumentParser.cpp:
1144 (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser): Add new didBlockScript() call.
1145 (WebCore::HTMLDocumentParser::pumpTokenizer):
1146 * html/parser/XSSAuditor.cpp: Renaming.
1147 (WebCore::XSSAuditor::filterToken):
1148 * html/parser/XSSAuditor.h: Renaming.
1151 * html/parser/XSSAuditorDelegate.cpp:
1152 (WebCore::XSSInfo::isSafeToSendToAnotherThread):
1154 (WebCore::XSSAuditorDelegate::didBlockScript):
1155 * html/parser/XSSAuditorDelegate.h:
1156 (WebCore::XSSInfo::create):
1158 (WebCore::XSSInfo::XSSInfo):
1159 (XSSAuditorDelegate):
1160 * platform/KURL.cpp:
1161 (WebCore::KURL::isSafeToSendToAnotherThread): Added.
1165 * platform/KURLGoogle.cpp:
1167 (WebCore::KURLGooglePrivate::isSafeToSendToAnotherThread): Added.
1168 * platform/KURLGooglePrivate.h:
1169 (KURLGooglePrivate):
1170 * platform/KURLWTFURLImpl.h:
1171 (WebCore::KURLWTFURLImpl::isSafeToSendToAnotherThread): Added.
1173 2013-02-06 Dean Jackson <dino@apple.com>
1175 Minor updates to captions menu UI
1176 https://bugs.webkit.org/show_bug.cgi?id=109005
1178 Reviewed by Eric Carlson.
1180 Now that we only have a single section in the captions menu, remove the
1181 unnecessary wrapper element. Also update the UI for Mac so that the menu
1182 grows in size dynamically, and change the text we display for a caption
1183 that has neither label or language identifiers.
1185 Covered by existing tests.
1187 * English.lproj/Localizable.strings: New string for an unknown caption label.
1188 * css/fullscreenQuickTime.css: New rules for the captions menu.
1189 (video:-webkit-full-screen::-webkit-media-controls-closed-captions-container):
1190 (video:-webkit-full-screen::-webkit-media-controls-closed-captions-track-list):
1191 * css/mediaControlsQuickTime.css: Ditto.
1192 (video::-webkit-media-controls-closed-captions-container):
1193 (video::-webkit-media-controls-closed-captions-track-list):
1194 * html/shadow/MediaControlElements.cpp:
1195 (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu):
1196 Remove the <section> element container.
1197 * platform/LocalizedStrings.cpp:
1198 (WebCore::textTrackNoLabelText): New string for an unknown caption label.
1200 2013-02-06 Vsevolod Vlasov <vsevik@chromium.org>
1202 Web Inspector: Remove isSnippet field from FileDescriptor and UISourceCode.
1203 https://bugs.webkit.org/show_bug.cgi?id=109045
1205 Reviewed by Pavel Feldman.
1207 Snippets are now distinguished based on uiSourceCode project.
1209 * inspector/front-end/JavaScriptSourceFrame.js:
1210 (WebInspector.JavaScriptSourceFrame.prototype._supportsEnabledBreakpointsWhileEditing):
1211 * inspector/front-end/NavigatorView.js:
1212 * inspector/front-end/ScriptSnippetModel.js:
1213 (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
1214 * inspector/front-end/ScriptsNavigator.js:
1215 (WebInspector.ScriptsNavigator.prototype._navigatorViewForUISourceCode):
1216 (WebInspector.ScriptsNavigator.prototype.addUISourceCode):
1217 (WebInspector.ScriptsNavigator.prototype.removeUISourceCode):
1218 (WebInspector.ScriptsNavigator.prototype.revealUISourceCode):
1219 (WebInspector.ScriptsNavigator.prototype.rename):
1220 (WebInspector.SnippetsNavigatorView.prototype._handleEvaluateSnippet):
1221 (WebInspector.SnippetsNavigatorView.prototype._handleRemoveSnippet):
1222 * inspector/front-end/ScriptsPanel.js:
1223 (WebInspector.ScriptsPanel.prototype._showFile):
1224 (WebInspector.ScriptsPanel.prototype._createSourceFrame):
1225 (WebInspector.ScriptsPanel.prototype.set _fileRenamed):
1226 * inspector/front-end/SimpleWorkspaceProvider.js:
1227 (WebInspector.SimpleWorkspaceProvider.prototype.addFile):
1228 (WebInspector.SimpleWorkspaceProvider.prototype.addFileForURL):
1229 * inspector/front-end/Workspace.js:
1230 (WebInspector.FileDescriptor):
1231 (WebInspector.Project.prototype._fileAdded):
1233 2013-02-06 Sheriff Bot <webkit.review.bot@gmail.com>
1235 Unreviewed, rolling out r141983.
1236 http://trac.webkit.org/changeset/141983
1237 https://bugs.webkit.org/show_bug.cgi?id=109055
1239 lots of new crashes in handlescope (Requested by gavinp on
1242 * bindings/v8/DOMDataStore.h:
1243 (WebCore::DOMDataStore::setWrapperInObject):
1244 * bindings/v8/DOMWrapperWorld.h:
1246 (WebCore::DOMWrapperWorld::isolated):
1247 * bindings/v8/V8Binding.h:
1249 (WebCore::worldForEnteredContextIfIsolated):
1250 * bindings/v8/V8DOMWindowShell.cpp:
1251 (WebCore::V8DOMWindowShell::initializeIfNeeded):
1252 * bindings/v8/V8GCController.cpp:
1253 (WebCore::WrapperVisitor::WrapperVisitor):
1256 (WebCore::V8GCController::didCreateWrapperForNode):
1257 (WebCore::V8GCController::gcPrologue):
1258 (WebCore::V8GCController::minorGCPrologue):
1259 (WebCore::V8GCController::majorGCPrologue):
1260 * bindings/v8/V8GCController.h:
1263 2013-02-06 Andreas Kling <akling@apple.com>
1265 Optimize GlyphPage for case where all glyphs are available in the same font.
1266 <http://webkit.org/b/108835>
1267 <rdar://problem/13157042>
1269 Reviewed by Antti Koivisto.
1271 Let GlyphPage begin optimistically assuming that all its glyphs will be represented in
1272 the same SimpleFontData*. In this (very common) case, only keep a single SimpleFontData*.
1274 If glyphs from multiple fonts are mixed in one page, an array of per-glyph SimpleFontData*
1275 is allocated transparently.
1277 4.98 MB progression on Membuster3.
1279 * platform/graphics/GlyphPageTreeNode.cpp:
1280 (WebCore::GlyphPageTreeNode::initializePage):
1281 * platform/graphics/GlyphPage.h:
1282 (WebCore::GlyphPage::createUninitialized):
1283 (WebCore::GlyphPage::createZeroedSystemFallbackPage):
1284 (WebCore::GlyphPage::createCopiedSystemFallbackPage):
1286 There are now three ways of constructing a GlyphPage, two of them are only used for
1287 creating system fallback pages.
1289 (WebCore::GlyphPage::setGlyphDataForIndex):
1291 Hold off creating a SimpleFontData* array until we're sure there are two different
1292 SimpleFontData* backing the glyphs in this page.
1293 We don't store font data for glyph #0, instead we let the getters always return null for it.
1295 (WebCore::GlyphPage::~GlyphPage):
1297 Free the SimpleFontData* array if needed.
1299 (WebCore::GlyphPage::glyphDataForCharacter):
1300 (WebCore::GlyphPage::glyphDataForIndex):
1301 (WebCore::GlyphPage::fontDataForCharacter):
1303 The font data for glyph #0 is always a null pointer now.
1305 (WebCore::GlyphPage::clearForFontData):
1307 Updated for new storage format.
1309 * rendering/svg/SVGTextRunRenderingContext.cpp:
1310 (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
1312 Fix bug where non-zero glyph was temporarily associated with null font data,
1313 which triggered the new assertion in setGlyphDataForIndex().
1315 2013-02-06 Pavel Feldman <pfeldman@chromium.org>
1317 Follow up to r141979: do not consume Home/End.
1320 * inspector/front-end/FilteredItemSelectionDialog.js:
1321 (WebInspector.FilteredItemSelectionDialog.prototype._onKeyDown):
1323 2013-02-06 Vsevolod Vlasov <vsevik@chromium.org>
1325 Web Inspector: Remove show script folders setting
1326 https://bugs.webkit.org/show_bug.cgi?id=108940
1328 Reviewed by Pavel Feldman.
1330 Removed showScriptFolders setting, the sources are never shown as a flat list in navigator anymore.
1332 * inspector/front-end/NavigatorView.js:
1333 (WebInspector.NavigatorView):
1334 (WebInspector.NavigatorView.prototype._getOrCreateFolderTreeElement):
1335 * inspector/front-end/Settings.js:
1336 * inspector/front-end/SettingsScreen.js:
1337 (WebInspector.GenericSettingsTab):
1339 2013-02-06 Andrey Lushnikov <lushnikov@chromium.org>
1341 Web Inspector: update javascriptsourcetokenizer to produce "whitespaces" token
1342 https://bugs.webkit.org/show_bug.cgi?id=108945
1344 Reviewed by Pavel Feldman.
1346 Update re2c grammar for SourceJavaScriptTokenizer to produce
1347 "whitespace" token which holds consequtive whitespaces in it.
1349 Updated existing tests expectations.
1351 * inspector/front-end/DOMSyntaxHighlighter.js:
1352 (WebInspector.DOMSyntaxHighlighter.prototype.createSpan): Do not strip spaces from tokens with class "whitespaces".
1353 * inspector/front-end/SourceJavaScriptTokenizer.js: Regenerated.
1354 (WebInspector.SourceJavaScriptTokenizer.prototype.nextToken):
1355 * inspector/front-end/SourceJavaScriptTokenizer.re2js:
1357 2013-02-06 Andrey Lushnikov <lushnikov@chromium.org>
1359 Web Inspector: refactor registerShortcuts method of DTE
1360 https://bugs.webkit.org/show_bug.cgi?id=109031
1362 Reviewed by Pavel Feldman.
1364 Implement _registerShortcuts method in TextEditorMainPanel which will
1365 bind its private methods to the different key combinations. Refactor
1366 method handlers handleUndoRedo, handleTabKeyPress and handleEnterKey
1367 from public to private.
1369 No new tests: no change in behaviour.
1371 * inspector/front-end/DefaultTextEditor.js:
1372 (WebInspector.DefaultTextEditor.prototype._registerShortcuts): Remove bindings of TextEditorMainPanel methods
1373 (WebInspector.DefaultTextEditor.prototype._handleKeyDown):
1374 (WebInspector.TextEditorMainPanel):
1375 (WebInspector.TextEditorMainPanel.prototype._registerShortcuts): Added.
1376 (WebInspector.TextEditorMainPanel.prototype._handleUndoRedo):
1377 (WebInspector.TextEditorMainPanel.prototype.handleKeyDown):
1379 2013-02-06 Mike West <mkwst@chromium.org>
1381 Add an ENABLE_NOSNIFF feature flag.
1382 https://bugs.webkit.org/show_bug.cgi?id=109029
1384 Reviewed by Jochen Eisinger.
1386 This new flag will control the behavior of 'X-Content-Type-Options: nosniff'
1387 when processing script and other resource types.
1389 * Configurations/FeatureDefines.xcconfig:
1391 2013-02-06 Tommy Widenflycht <tommyw@google.com>
1393 MediaStream API: Implement DTMF support in RTCPeerConnection
1394 https://bugs.webkit.org/show_bug.cgi?id=106782
1396 Reviewed by Adam Barth.
1398 The WebRTC specification have added support for DTMF:
1399 http://dev.w3.org/2011/webrtc/editor/webrtc.html#peer-to-peer-dtmf
1401 Implementation wise this is implemented using the same pattern as RTCDataChannel;
1402 where a RTCDTMFSenderHandler is created by the UA through a new method on
1403 RTCPeerConnectionHandler.
1405 Test: fast/mediastream/RTCPeerConnection-dtmf.html
1408 * GNUmakefile.list.am:
1409 * Modules/mediastream/RTCDTMFSender.cpp: Added.
1411 (WebCore::RTCDTMFSender::create):
1412 (WebCore::RTCDTMFSender::RTCDTMFSender):
1413 (WebCore::RTCDTMFSender::~RTCDTMFSender):
1414 (WebCore::RTCDTMFSender::canInsertDTMF):
1415 (WebCore::RTCDTMFSender::track):
1416 (WebCore::RTCDTMFSender::toneBuffer):
1417 (WebCore::RTCDTMFSender::insertDTMF):
1418 (WebCore::RTCDTMFSender::didPlayTone):
1419 (WebCore::RTCDTMFSender::interfaceName):
1420 (WebCore::RTCDTMFSender::scriptExecutionContext):
1421 (WebCore::RTCDTMFSender::stop):
1422 (WebCore::RTCDTMFSender::eventTargetData):
1423 (WebCore::RTCDTMFSender::ensureEventTargetData):
1424 (WebCore::RTCDTMFSender::scheduleDispatchEvent):
1425 (WebCore::RTCDTMFSender::scheduledEventTimerFired):
1426 * Modules/mediastream/RTCDTMFSender.h: Added.
1429 (WebCore::RTCDTMFSender::duration):
1430 (WebCore::RTCDTMFSender::interToneGap):
1431 * Modules/mediastream/RTCDTMFSender.idl: Added.
1432 * Modules/mediastream/RTCDTMFToneChangeEvent.cpp: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1434 (WebCore::RTCDTMFToneChangeEvent::create):
1435 (WebCore::RTCDTMFToneChangeEvent::RTCDTMFToneChangeEvent):
1436 (WebCore::RTCDTMFToneChangeEvent::~RTCDTMFToneChangeEvent):
1437 (WebCore::RTCDTMFToneChangeEvent::tone):
1438 (WebCore::RTCDTMFToneChangeEvent::interfaceName):
1439 * Modules/mediastream/RTCDTMFToneChangeEvent.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1441 (RTCDTMFToneChangeEventInit):
1442 (RTCDTMFToneChangeEvent):
1443 * Modules/mediastream/RTCDTMFToneChangeEvent.idl: Added.
1444 * Modules/mediastream/RTCPeerConnection.cpp:
1445 (WebCore::RTCPeerConnection::createDataChannel):
1447 (WebCore::RTCPeerConnection::getStreamByTrackId):
1448 (WebCore::RTCPeerConnection::createDTMFSender):
1449 * Modules/mediastream/RTCPeerConnection.h:
1451 (RTCPeerConnection):
1452 * Modules/mediastream/RTCPeerConnection.idl:
1456 * dom/EventNames.in:
1457 * dom/EventTargetFactory.in:
1458 * platform/chromium/support/WebMediaStreamTrack.cpp:
1459 (WebKit::WebMediaStreamTrack::WebMediaStreamTrack):
1461 * platform/mediastream/RTCDTMFSenderHandler.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1463 (RTCDTMFSenderHandler):
1464 (WebCore::RTCDTMFSenderHandler::~RTCDTMFSenderHandler):
1465 * platform/mediastream/RTCDTMFSenderHandlerClient.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1467 (RTCDTMFSenderHandlerClient):
1468 (WebCore::RTCDTMFSenderHandlerClient::~RTCDTMFSenderHandlerClient):
1469 * platform/mediastream/RTCPeerConnectionHandler.h:
1471 (RTCPeerConnectionHandler):
1472 * platform/mediastream/chromium/RTCDTMFSenderHandlerChromium.cpp: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1474 (WebCore::RTCDTMFSenderHandlerChromium::create):
1475 (WebCore::RTCDTMFSenderHandlerChromium::RTCDTMFSenderHandlerChromium):
1476 (WebCore::RTCDTMFSenderHandlerChromium::~RTCDTMFSenderHandlerChromium):
1477 (WebCore::RTCDTMFSenderHandlerChromium::setClient):
1478 (WebCore::RTCDTMFSenderHandlerChromium::currentToneBuffer):
1479 (WebCore::RTCDTMFSenderHandlerChromium::canInsertDTMF):
1480 (WebCore::RTCDTMFSenderHandlerChromium::insertDTMF):
1481 (WebCore::RTCDTMFSenderHandlerChromium::didPlayTone):
1482 * platform/mediastream/chromium/RTCDTMFSenderHandlerChromium.h: Copied from Source/Platform/chromium/public/WebMediaStreamTrack.h.
1484 (RTCDTMFSenderHandlerChromium):
1485 * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
1486 (WebCore::RTCPeerConnectionHandlerChromium::createDTMFSender):
1488 * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
1489 (RTCPeerConnectionHandlerChromium):
1491 2013-02-04 Kentaro Hara <haraken@chromium.org>
1493 [V8] Remove V8GCController::m_edenNodes and make minor DOM GC more precise
1494 https://bugs.webkit.org/show_bug.cgi?id=108579
1496 Reviewed by Adam Barth.
1498 Currently V8GCController::m_edenNodes stores a list of nodes whose
1499 wrappers have been created since the latest GC. The reason why we
1500 needed m_edenNodes is that there was no way to know a list of wrappers
1501 in the new space of V8. By using m_edenNodes, we had been approximating
1502 'wrappers in the new space' by 'wrappers that have been created since
1505 Now V8 provides VisitHandlesForPartialDependence(), with which WebKit
1506 can know a list of wrappers in the new space. By using the API, we can
1507 remove V8GCController::m_edenNodes. The benefit is that (1) we no longer
1508 need to keep m_edenNodes and that (2) it enables more precise minor
1509 DOM GC (Remember that m_edenNodes was just an approximation).
1511 Performance benchmark: https://bugs.webkit.org/attachment.cgi?id=185940
1512 The benchmark runs 300 iterations, each of which creates 100000 elements.
1513 The benchmark measures average, min, median, max and stdev of execution times
1514 of the 300 iterations. This will tell us the worst-case overhead of this change.
1517 mean=59.91ms, min=39ms, median=42ms, max=258ms, stdev=47.48ms
1520 mean=58.75ms, min=35ms, median=41ms, max=250ms, stdev=47.32ms
1522 As shown above, I couldn't observe any performance regression.
1524 No tests. No change in behavior.
1526 * bindings/v8/DOMDataStore.h:
1527 (WebCore::DOMDataStore::setWrapperInObject):
1528 * bindings/v8/DOMWrapperWorld.h:
1530 (WebCore::DOMWrapperWorld::getWorldWithoutContextCheck):
1531 * bindings/v8/V8Binding.h:
1533 (WebCore::worldForEnteredContextIfIsolated):
1534 (WebCore::worldForEnteredContextWithoutContextCheck):
1535 * bindings/v8/V8DOMWindowShell.cpp:
1536 (WebCore::V8DOMWindowShell::initializeIfNeeded):
1537 * bindings/v8/V8GCController.cpp:
1540 (MinorGCWrapperVisitor):
1541 (WebCore::MinorGCWrapperVisitor::MinorGCWrapperVisitor):
1542 (WebCore::MinorGCWrapperVisitor::notifyFinished):
1543 (WebCore::MajorGCWrapperVisitor::MajorGCWrapperVisitor):
1544 (WebCore::V8GCController::gcPrologue):
1545 (WebCore::V8GCController::minorGCPrologue):
1546 (WebCore::V8GCController::majorGCPrologue):
1547 * bindings/v8/V8GCController.h:
1550 2013-02-06 Mihai Maerean <mmaerean@adobe.com>
1552 [CSSRegions] Assertion failure in Node::detach (!renderer || renderer->inRenderFlowThread())
1553 https://bugs.webkit.org/show_bug.cgi?id=104517
1555 Reviewed by Julien Chaffraix.
1557 The RenderObject::inRenderFlowThread bit could have become disconnected from the fact that the RenderObject
1558 has (or not) an enclosing RenderFlowThread.
1559 The cause of this was that, when setting or removing the parent of a RenderObject, the inRenderFlowThread flags
1560 wasn't being set/reset for the children too.
1561 This is now fixed by calling the new setInRenderFlowThreadIncludingDescendants.
1563 The ASSERT was hit for anonymous blocks when detaching the document.
1565 Test: fast/regions/detaching-regions-with-anonymous-blocks.html
1567 * rendering/RenderObject.cpp:
1568 (WebCore::RenderObject::setInRenderFlowThreadRecursive):
1570 * rendering/RenderObject.h:
1571 (WebCore::RenderObject::setParent):
1574 2013-02-06 Marja Hölttä <marja@chromium.org>
1576 Take referrer policy into account when clearing the referrer header
1577 https://bugs.webkit.org/show_bug.cgi?id=86000
1579 Reviewed by Alexey Proskuryakov.
1581 The referrer should only be cleared when doing a https -> http redirect,
1582 if the policy is "default". Otherwise the referrer should be left intact.
1584 In order to do that, added a function for checking the policy in
1585 NetworkingContext, and stored the NetworkingContext in ResourceHandle
1586 (like some ports already did).
1588 No new tests (unskipped old tests).
1590 * loader/FrameNetworkingContext.h:
1591 (WebCore::FrameNetworkingContext::shouldClearReferrerOnHTTPSToHTTPRedirect):
1592 (FrameNetworkingContext):
1593 * platform/network/BlobResourceHandle.cpp:
1594 (WebCore::BlobResourceHandle::BlobResourceHandle):
1595 * platform/network/NetworkingContext.h:
1596 (NetworkingContext):
1597 * platform/network/ResourceHandle.cpp:
1598 (WebCore::ResourceHandle::ResourceHandle):
1599 (WebCore::ResourceHandle::create):
1600 (WebCore::ResourceHandle::context):
1602 * platform/network/ResourceHandle.h:
1604 * platform/network/ResourceHandleInternal.h:
1605 (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1606 (ResourceHandleInternal):
1607 * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
1608 (WebCore::ResourceHandle::start):
1609 (WebCore::ResourceHandle::loadResourceSynchronously):
1610 * platform/network/cf/ResourceHandleCFNet.cpp:
1611 (WebCore::willSendRequest):
1612 (WebCore::ResourceHandle::start):
1613 (WebCore::ResourceHandle::loadResourceSynchronously):
1614 * platform/network/chromium/ResourceHandle.cpp:
1615 (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1616 (WebCore::ResourceHandle::ResourceHandle):
1617 (WebCore::ResourceHandle::create):
1618 (WebCore::ResourceHandle::context):
1620 (WebCore::ResourceHandle::start):
1621 * platform/network/chromium/ResourceHandleInternal.h:
1623 (ResourceHandleInternal):
1624 (WebCore::ResourceHandleInternal::context):
1625 * platform/network/curl/ResourceHandleCurl.cpp:
1626 (WebCore::ResourceHandle::start):
1627 (WebCore::ResourceHandle::loadResourceSynchronously):
1628 * platform/network/mac/ResourceHandleMac.mm:
1629 (WebCore::ResourceHandle::start):
1630 (WebCore::ResourceHandle::loadResourceSynchronously):
1631 (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]):
1632 * platform/network/qt/QNetworkReplyHandler.cpp:
1633 (WebCore::QNetworkReplyHandler::redirect):
1634 * platform/network/qt/ResourceHandleQt.cpp:
1635 (WebCore::ResourceHandle::start):
1636 (WebCore::ResourceHandle::loadResourceSynchronously):
1637 * platform/network/soup/ResourceHandleSoup.cpp:
1638 (WebCore::doRedirect):
1639 (WebCore::ResourceHandle::start):
1640 * platform/network/win/ResourceHandleWin.cpp:
1641 (WebCore::ResourceHandle::start):
1642 (WebCore::ResourceHandle::loadResourceSynchronously):
1644 2013-02-06 Pavel Feldman <pfeldman@chromium.org>
1646 Web Inspector: file selector list jumps as I type or move Up/Down
1647 https://bugs.webkit.org/show_bug.cgi?id=108933
1649 Reviewed by Vsevolod Vlasov.
1651 Missing return was scheduling extra updates.
1653 * inspector/front-end/FilteredItemSelectionDialog.js:
1654 (WebInspector.FilteredItemSelectionDialog):
1655 (WebInspector.FilteredItemSelectionDialog.prototype._filterItems):
1656 (WebInspector.FilteredItemSelectionDialog.prototype._onKeyDown):
1657 (WebInspector.FilteredItemSelectionDialog.prototype._updateSelection):
1659 2013-02-06 Kentaro Hara <haraken@chromium.org>
1661 [V8] Pass an Isolate to remaining GetTemplate()s
1662 https://bugs.webkit.org/show_bug.cgi?id=109001
1664 Reviewed by Adam Barth.
1666 No tests. No change in behavior.
1668 * bindings/v8/custom/V8DOMWindowCustom.cpp:
1669 (WebCore::V8DOMWindow::namedSecurityCheck): Because this method is a callback from V8,
1670 we cannot change its signature to receive an Isolate.
1671 (WebCore::V8DOMWindow::indexedSecurityCheck): Ditto.
1673 * bindings/scripts/CodeGeneratorV8.pm:
1675 (GenerateToV8Converters):
1676 * bindings/scripts/test/V8/V8Float64Array.cpp:
1677 (WebCore::V8Float64Array::createWrapper):
1678 * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1679 (WebCore::V8TestActiveDOMObject::createWrapper):
1680 * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1681 (WebCore::V8TestCustomNamedGetter::createWrapper):
1682 * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1683 (WebCore::V8TestEventConstructor::createWrapper):
1684 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1685 (WebCore::V8TestEventTarget::createWrapper):
1686 * bindings/scripts/test/V8/V8TestException.cpp:
1687 (WebCore::V8TestException::createWrapper):
1688 * bindings/scripts/test/V8/V8TestInterface.cpp:
1689 (WebCore::V8TestInterface::createWrapper):
1690 * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1691 (WebCore::V8TestMediaQueryListListener::createWrapper):
1692 * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1693 (WebCore::V8TestNamedConstructor::createWrapper):
1694 * bindings/scripts/test/V8/V8TestNode.cpp:
1695 (WebCore::V8TestNode::createWrapper):
1696 * bindings/scripts/test/V8/V8TestObj.cpp:
1697 (WebCore::V8TestObj::createWrapper):
1698 * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
1699 (WebCore::V8TestOverloadedConstructors::createWrapper):
1700 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1701 (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
1702 * bindings/v8/V8DOMWrapper.cpp:
1703 (WebCore::V8DOMWrapper::createWrapper):
1704 * bindings/v8/V8DOMWrapper.h:
1706 * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1707 (WebCore::V8HTMLDocument::wrapInShadowObject):
1709 2013-02-06 Sheriff Bot <webkit.review.bot@gmail.com>
1711 Unreviewed, rolling out r141961.
1712 http://trac.webkit.org/changeset/141961
1713 https://bugs.webkit.org/show_bug.cgi?id=109019
1715 assertion failures on svn tests such as fonts-glyph-04-t.svg
1716 (Requested by falken on #webkit).
1718 * platform/graphics/GlyphPage.h:
1719 (WebCore::GlyphPage::create):
1720 (WebCore::GlyphPage::glyphDataForCharacter):
1721 (WebCore::GlyphPage::glyphDataForIndex):
1722 (WebCore::GlyphPage::fontDataForCharacter):
1723 (WebCore::GlyphPage::setGlyphDataForIndex):
1725 (WebCore::GlyphPage::copyFrom):
1726 (WebCore::GlyphPage::clear):
1727 (WebCore::GlyphPage::clearForFontData):
1728 (WebCore::GlyphPage::GlyphPage):
1729 * platform/graphics/GlyphPageTreeNode.cpp:
1730 (WebCore::GlyphPageTreeNode::initializePage):
1732 2013-02-05 Sheriff Bot <webkit.review.bot@gmail.com>
1734 Unreviewed, rolling out r141964.
1735 http://trac.webkit.org/changeset/141964
1736 https://bugs.webkit.org/show_bug.cgi?id=109014
1738 caused performance regression (Requested by hayato on
1742 * GNUmakefile.list.am:
1745 * WebCore.xcodeproj/project.pbxproj:
1746 * css/CSSAllInOne.cpp:
1747 * css/DocumentRuleSets.cpp: Removed.
1748 * css/DocumentRuleSets.h: Removed.
1749 * css/StyleResolver.cpp:
1750 (WebCore::StyleResolver::StyleResolver):
1751 (WebCore::StyleResolver::collectRulesFromUserStyleSheets):
1753 (WebCore::makeRuleSet):
1754 (WebCore::StyleResolver::resetAuthorStyle):
1755 (WebCore::StyleResolver::appendAuthorStyleSheets):
1756 (WebCore::StyleResolver::matchAuthorRules):
1757 (WebCore::StyleResolver::matchUserRules):
1758 (WebCore::StyleResolver::classNamesAffectedByRules):
1759 (WebCore::StyleResolver::locateCousinList):
1760 (WebCore::StyleResolver::canShareStyleWithElement):
1761 (WebCore::StyleResolver::locateSharedStyle):
1762 (WebCore::StyleResolver::styleForElement):
1763 (WebCore::StyleResolver::styleForPage):
1764 (WebCore::StyleResolver::checkRegionStyle):
1765 (WebCore::StyleResolver::applyProperty):
1766 (WebCore::StyleResolver::collectFeatures):
1767 (WebCore::StyleResolver::reportMemoryUsage):
1768 * css/StyleResolver.h:
1770 (WebCore::StyleResolver::usesSiblingRules):
1771 (WebCore::StyleResolver::usesFirstLineRules):
1772 (WebCore::StyleResolver::usesBeforeAfterRules):
1773 (WebCore::StyleResolver::hasSelectorForAttribute):
1774 (WebCore::StyleResolver::hasSelectorForClass):
1775 (WebCore::StyleResolver::hasSelectorForId):
1776 * dom/DocumentStyleSheetCollection.cpp:
1777 (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
1779 2013-02-05 Kentaro Hara <haraken@chromium.org>
1781 Add #if USE(V8) to Node::V8CollectableDuringMinorGCFlag
1782 https://bugs.webkit.org/show_bug.cgi?id=109009
1784 Reviewed by Kent Tamura.
1786 Node flags should be saved. V8CollectableDuringMinorGCFlag is used by V8 only.
1791 2013-02-05 Vsevolod Vlasov <vsevik@chromium.org>
1793 Web Inspector: Add ending slashes automatically to file mappings.
1794 https://bugs.webkit.org/show_bug.cgi?id=108936
1796 Reviewed by Pavel Feldman.
1798 * inspector/front-end/SettingsScreen.js:
1799 (WebInspector.WorkspaceSettingsTab.prototype._addFileMappingClicked):
1801 2013-02-05 Eric Carlson <eric.carlson@apple.com>
1803 More updates to Caption user preferences
1804 https://bugs.webkit.org/show_bug.cgi?id=108997
1806 Reviewed by Dean Jackson.
1808 * html/HTMLMediaElement.cpp:
1809 (WebCore::HTMLMediaElement::captionPreferencesChanged): Give the media controls a chance
1810 to update for a preferences change.
1811 * html/shadow/MediaControlElements.cpp:
1812 (WebCore::MediaControlTextTrackContainerElement::updateSizes): Add optional "force update"
1813 param to force font size recalc even when the video size hasn't changed.
1814 * html/shadow/MediaControlElements.h:
1816 * html/shadow/MediaControls.cpp:
1817 (WebCore::MediaControls::textTrackPreferencesChanged): New, force a font size recalc.
1818 * html/shadow/MediaControls.h:
1820 * html/track/TextTrackCueGeneric.cpp:
1821 (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties): Don't set width/size of cues
1822 that use default positioning. Use "start" as the default alignment.
1824 * page/CaptionUserPreferencesMac.mm:
1825 (WebCore::CaptionUserPreferencesMac::captionsWindowCSS): Set padding when the window is visible
1826 so it shows around the cue background.
1827 (WebCore::CaptionUserPreferencesMac::captionsBackgroundCSS): Set padding to 0 when the background
1829 (WebCore::CaptionUserPreferencesMac::windowRoundedCornerRadiusCSS): Add "px" to the border radius
1830 so it actually works.
1831 * rendering/RenderTextTrackCue.cpp:
1832 (WebCore::RenderTextTrackCue::layout): Special case generic cues with default style.
1833 (WebCore::RenderTextTrackCue::repositionGenericCue):
1834 * rendering/RenderTextTrackCue.h:
1836 2013-02-05 Hayato Ito <hayato@chromium.org>
1838 Split each RuleSet and feature out from StyleResolver into its own class.
1839 https://bugs.webkit.org/show_bug.cgi?id=107777
1841 Reviewed by Dimitri Glazkov.
1843 Splitting each RuleSet and feature out from StyleResover into its onw class, DocumentRuleSets,
1844 to manage them separately.
1846 This is one of the attempts to try to resolve meta bug (bug 89879)
1847 to lose StyleResolver's weight. We need further action to factor
1848 StyleResolver to separate it into some classes cleanly.
1849 See also https://bugs.webkit.org/show_bug.cgi?id=108890. A following patch will address that.
1851 No tests. No change in behavior.
1854 * GNUmakefile.list.am:
1857 * WebCore.xcodeproj/project.pbxproj:
1858 * css/CSSAllInOne.cpp:
1859 * css/DocumentRuleSets.cpp: Added.
1861 (WebCore::DocumentRuleSets::DocumentRuleSets):
1862 (WebCore::DocumentRuleSets::~DocumentRuleSets):
1863 (WebCore::DocumentRuleSets::initUserStyle): New helper to initialize each RuleSets.
1864 (WebCore::DocumentRuleSets::collectRulesFromUserStyleSheets): Factored out from StyleResolver.
1865 (WebCore::makeRuleSet): Ditto.
1866 (WebCore::DocumentRuleSets::resetAuthorStyle): Ditto.
1867 (WebCore::DocumentRuleSets::appendAuthorStyleSheets): Ditto.
1868 (WebCore::DocumentRuleSets::collectFeatures): Ditto.
1869 (WebCore::DocumentRuleSets::reportMemoryUsage): New methods to report memory usage. Factored out from StyleResolver.
1870 * css/DocumentRuleSets.h: Added.
1873 (WebCore::DocumentRuleSets::authorStyle): Moved from StyleResolver.
1874 (WebCore::DocumentRuleSets::userStyle): Ditto.
1875 (WebCore::DocumentRuleSets::features): Ditto.
1876 (WebCore::DocumentRuleSets::sibling): Ditto.
1877 (WebCore::DocumentRuleSets::uncommonAttribute): Ditto.
1878 * css/StyleResolver.cpp:
1879 (WebCore::StyleResolver::StyleResolver):
1880 (WebCore::StyleResolver::appendAuthorStyleSheets): Now calls DocumentRuleSets::appendAuthorStyleSheets.
1881 (WebCore::StyleResolver::matchAuthorRules): Use m_ruleSets.
1882 (WebCore::StyleResolver::matchUserRules): Ditto.
1883 (WebCore::StyleResolver::classNamesAffectedByRules): Ditto.
1884 (WebCore::StyleResolver::locateCousinList): Ditto.
1885 (WebCore::StyleResolver::canShareStyleWithElement): Ditto.
1886 (WebCore::StyleResolver::locateSharedStyle): Ditto.
1887 (WebCore::StyleResolver::styleForPage): Ditto.
1888 (WebCore::StyleResolver::checkRegionStyle): Ditto.
1889 (WebCore::StyleResolver::applyProperty): Ditto.
1890 (WebCore::StyleResolver::reportMemoryUsage): Now calls DocumentRuleSets::reportMemoryUsage.
1891 * css/StyleResolver.h:
1892 (WebCore::StyleResolver::scopeResolver):
1894 (WebCore::StyleResolver::ruleSets): accessor r to DocumentRuleSets.
1895 (WebCore::StyleResolver::usesSiblingRules): Use m_ruleSets.
1896 (WebCore::StyleResolver::usesFirstLineRules): Ditto.
1897 (WebCore::StyleResolver::usesBeforeAfterRules): Ditto.
1898 (WebCore::StyleResolver::hasSelectorForAttribute): Ditto.
1899 (WebCore::StyleResolver::hasSelectorForClass): Ditto.
1900 (WebCore::StyleResolver::hasSelectorForId): Ditto.
1901 * dom/DocumentStyleSheetCollection.cpp:
1902 (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
1904 2013-02-05 Julien Chaffraix <jchaffraix@webkit.org>
1906 [CSS Grid Layout] Grid item's logical height is not properly recomputed after -webkit-grid-column / -webkit-grid-row changes
1907 https://bugs.webkit.org/show_bug.cgi?id=108975
1909 Reviewed by Tony Chang.
1911 Test: fast/css-grid-layout/implicit-position-dynamic-change.html
1913 * rendering/RenderBox.cpp:
1914 (WebCore::RenderBox::clearContainingBlockOverrideSize):
1915 (WebCore::RenderBox::clearOverrideContainingBlockContentLogicalHeight):
1916 * rendering/RenderBox.h:
1917 Added clearOverrideContainingBlockContentLogicalHeight and updated clearContainingBlockOverrideSize
1920 * rendering/RenderGrid.cpp:
1921 (WebCore::RenderGrid::minContentForChild):
1922 (WebCore::RenderGrid::maxContentForChild):
1923 Added missing clearContainingBlockOverrideSize to ensure we don't use a previous layout's override.
1925 2013-02-05 Andreas Kling <akling@apple.com>
1927 Optimize GlyphPage for case where all glyphs are available in the same font.
1928 <http://webkit.org/b/108835>
1929 <rdar://problem/13157042>
1931 Reviewed by Antti Koivisto.
1933 Let GlyphPage begin optimistically assuming that all its glyphs will be represented in
1934 the same SimpleFontData*. In this (very common) case, only keep a single SimpleFontData*.
1936 If glyphs from multiple fonts are mixed in one page, an array of per-glyph SimpleFontData*
1937 is allocated transparently.
1939 4.98 MB progression on Membuster3.
1941 * platform/graphics/GlyphPageTreeNode.cpp:
1942 (WebCore::GlyphPageTreeNode::initializePage):
1943 * platform/graphics/GlyphPage.h:
1944 (WebCore::GlyphPage::createUninitialized):
1945 (WebCore::GlyphPage::createZeroedSystemFallbackPage):
1946 (WebCore::GlyphPage::createCopiedSystemFallbackPage):
1948 There are now three ways of constructing a GlyphPage, two of them are only used for
1949 creating system fallback pages.
1951 (WebCore::GlyphPage::setGlyphDataForIndex):
1953 Hold off creating a SimpleFontData* array until we're sure there are two different
1954 SimpleFontData* backing the glyphs in this page.
1955 We don't store font data for glyph #0, instead we let the getters always return null for it.
1957 (WebCore::GlyphPage::~GlyphPage):
1959 Free the SimpleFontData* array if needed.
1961 (WebCore::GlyphPage::glyphDataForCharacter):
1962 (WebCore::GlyphPage::glyphDataForIndex):
1963 (WebCore::GlyphPage::fontDataForCharacter):
1965 The font data for glyph #0 is always a null pointer now.
1967 (WebCore::GlyphPage::clearForFontData):
1969 Updated for new storage format.
1971 2013-02-05 Kent Tamura <tkent@chromium.org>
1973 INPUT_MULTIPLE_FIELDS_UI: Read-only inputs should be focusable
1974 https://bugs.webkit.org/show_bug.cgi?id=108795
1976 Reviewed by Kentaro Hara.
1978 According to the standard [1], readonly form controls should be focusable.
1980 - Sub-fields should be focusable if they are read-only. We should check
1982 - All keyboard operations should not be handled if a field is disabled,
1983 and focus navigation keyboard operations should be handled even if a
1986 [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#the-readonly-attribute
1988 No new tests. Update
1989 fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html
1990 for the new behavior.
1992 * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
1993 (WebCore::BaseMultipleFieldsDateAndTimeInputType::isKeyboardFocusable):
1994 Make <input> focusable even if it is read-only.
1995 * html/shadow/DateTimeEditElement.cpp:
1996 (WebCore::DateTimeEditElement::isFieldOwnerDisabled):
1997 Separate isFieldOwnerDisabledOrReadOnly into two.
1998 (WebCore::DateTimeEditElement::isFieldOwnerReadOnly): Ditto.
1999 (WebCore::DateTimeEditElement::updateUIState):
2000 We don't need to focus out if this is read-only.
2001 * html/shadow/DateTimeEditElement.h:
2002 (DateTimeEditElement): Separate isFieldOwnerDisabledOrReadOnly into two.
2003 * html/shadow/DateTimeFieldElement.cpp:
2004 (WebCore::DateTimeFieldElement::defaultEventHandler):
2005 Skip handleKeyboardEvent if the field is disabled or the owner input is
2006 disabled or read-only. handleKeyboardEvent handles editing key
2008 (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler):
2009 If this field is disabled or the owner input is disabled, all keyboard
2011 If this field is read-only, we handle only left and right arrows to
2012 change focus, and skip down/up/backspace/del keys.
2013 (WebCore::DateTimeFieldElement::isFieldOwnerDisabled):
2014 A helper function to check disable state of the owner input.
2015 (WebCore::DateTimeFieldElement::isFieldOwnerReadOnly):
2016 A helper function to check read-only state of the owner input.
2017 (WebCore::DateTimeFieldElement::isFocusable):
2018 This field should be focusable if it is read-only and not disabled.
2019 * html/shadow/DateTimeFieldElement.h:
2020 (FieldOwner): Separate isFieldOwnerDisabledOrReadOnly into two.
2021 (DateTimeFieldElement):
2022 Declare isFieldOwnerDisabled and isFieldOwnerReadOnly.
2023 * html/shadow/DateTimeNumericFieldElement.cpp:
2024 (WebCore::DateTimeNumericFieldElement::handleKeyboardEvent):
2025 Remove redundant isDisabled check. It is done in
2026 DateTimeFieldElement::defaultEventHandler.
2028 2013-02-05 Eric Carlson <eric.carlson@apple.com>
2030 [Mac] Complete plumbing so captions menu can indicate track type
2031 https://bugs.webkit.org/show_bug.cgi?id=108994
2033 Reviewed by Dean Jackson.
2035 Plumb "isClosedCaptions" through to the Mac media engine.
2037 Updated media/video-controls-captions-trackmenu-localized.html and results.
2039 * html/track/InbandTextTrack.cpp:
2040 (WebCore::InbandTextTrack::isClosedCaptions): New, pass the call through to the private track.
2041 * html/track/InbandTextTrack.h:
2043 * html/track/TextTrack.cpp:
2044 (WebCore::TextTrack::TextTrack): Lose the member variable, this won't be accessed often enough
2045 to make it worth caching the value.
2046 * html/track/TextTrack.h:
2047 (WebCore::TextTrack::isClosedCaptions): Make virtual so derived classes can oveerride.
2048 * platform/graphics/InbandTextTrackPrivate.h:
2049 (WebCore::InbandTextTrackPrivate::isClosedCaptions): New.
2050 * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
2051 * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
2052 (WebCore::InbandTextTrackPrivateAVFObjC::isClosedCaptions): New.
2054 2013-02-05 Mark Lam <mark.lam@apple.com>
2056 Change DatabaseTask and DatabaseThread to work with DatabaseBackendAsync
2057 instead of Database.
2058 https://bugs.webkit.org/show_bug.cgi?id=108995.
2060 Reviewed by Sam Weinig.
2062 This change also moves the task inner classes from Database to
2063 DatabaseBackendAsync.
2067 * Modules/webdatabase/Database.cpp:
2068 (WebCore::Database::from):
2069 * Modules/webdatabase/Database.h:
2071 * Modules/webdatabase/DatabaseBackend.h:
2073 * Modules/webdatabase/DatabaseBackendAsync.h:
2074 (DatabaseBackendAsync):
2075 * Modules/webdatabase/DatabaseTask.cpp:
2076 (WebCore::DatabaseTask::DatabaseTask):
2077 (WebCore::DatabaseBackendAsync::DatabaseOpenTask::DatabaseOpenTask):
2078 (WebCore::DatabaseBackendAsync::DatabaseOpenTask::doPerformTask):
2079 (WebCore::DatabaseBackendAsync::DatabaseOpenTask::debugTaskName):
2080 (WebCore::DatabaseBackendAsync::DatabaseCloseTask::DatabaseCloseTask):
2081 (WebCore::DatabaseBackendAsync::DatabaseCloseTask::doPerformTask):
2082 (WebCore::DatabaseBackendAsync::DatabaseCloseTask::debugTaskName):
2083 (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::DatabaseTransactionTask):
2084 (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::doPerformTask):
2085 (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::debugTaskName):
2086 (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::DatabaseTableNamesTask):
2087 (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::doPerformTask):
2088 (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::debugTaskName):
2089 * Modules/webdatabase/DatabaseTask.h:
2090 (WebCore::DatabaseTask::database):
2092 (WebCore::DatabaseBackendAsync::DatabaseOpenTask::create):
2093 (DatabaseBackendAsync::DatabaseOpenTask):
2094 (WebCore::DatabaseBackendAsync::DatabaseCloseTask::create):
2095 (DatabaseBackendAsync::DatabaseCloseTask):
2096 (WebCore::DatabaseBackendAsync::DatabaseTableNamesTask::create):
2097 (DatabaseBackendAsync::DatabaseTableNamesTask):
2098 * Modules/webdatabase/DatabaseThread.cpp:
2099 (WebCore::DatabaseThread::databaseThread):
2100 (WebCore::DatabaseThread::recordDatabaseOpen):
2101 (WebCore::DatabaseThread::recordDatabaseClosed):
2102 (WebCore::SameDatabasePredicate::SameDatabasePredicate):
2103 (SameDatabasePredicate):
2104 (WebCore::DatabaseThread::unscheduleDatabaseTasks):
2105 * Modules/webdatabase/DatabaseThread.h:
2108 2013-02-05 Mark Lam <mark.lam@apple.com>
2110 Rename ENUM_CLASS_BEGIN() macro to ENUM_CLASS(), and make DatabaseType a strong enum.
2111 https://bugs.webkit.org/show_bug.cgi?id=108988.
2113 Reviewed by Alexey Proskuryakov.
2117 * Modules/webdatabase/DatabaseBackend.cpp:
2118 (WebCore::DatabaseBackend::DatabaseBackend):
2119 * Modules/webdatabase/DatabaseBackend.h:
2121 * Modules/webdatabase/DatabaseBackendAsync.cpp:
2122 (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
2123 * Modules/webdatabase/DatabaseBackendSync.cpp:
2124 (WebCore::DatabaseBackendSync::DatabaseBackendSync):
2125 * Modules/webdatabase/DatabaseBasicTypes.h:
2126 (WebCore::ENUM_CLASS):
2127 * Modules/webdatabase/DatabaseError.h:
2128 (WebCore::ENUM_CLASS):
2130 2013-02-05 Kentaro Hara <haraken@chromium.org>
2132 [V8] Remove deprecatedV8String() and deprecatedV8Integer()
2133 https://bugs.webkit.org/show_bug.cgi?id=108919
2135 Reviewed by Adam Barth.
2137 No tests. No change in behavior.
2139 * bindings/v8/V8Binding.cpp:
2140 (WebCore::toXPathNSResolver):
2141 * bindings/v8/V8Binding.h:
2142 * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
2143 (WebCore::V8CustomXPathNSResolver::create):
2144 (WebCore::V8CustomXPathNSResolver::V8CustomXPathNSResolver):
2145 (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
2146 * bindings/v8/custom/V8CustomXPathNSResolver.h:
2147 (V8CustomXPathNSResolver):
2149 2013-02-05 Vineet Chaudhary <rgf748@motorola.com>
2151 formenctype to have empty string as default value.
2152 https://bugs.webkit.org/show_bug.cgi?id=108969
2154 Reviewed by Kent Tamura.
2156 The spec says formEnctype should only have an invalid value default, not a missing value default.
2157 Spec: http://www.w3.org/html/wg/drafts/html/master/forms.html#attr-fs-formenctype
2158 http://www.whatwg.org/specs/web-apps/current-work/#attr-fs-formenctype
2160 No new tests. Covered by existing test case fast/forms/submit-form-attributes.html
2162 * html/HTMLFormControlElement.cpp: For the missing formEnctype attr return empty string.
2163 (WebCore::HTMLFormControlElement::formEnctype):
2165 2013-02-04 Kentaro Hara <haraken@chromium.org>
2167 [V8] Reduce usage of deprecatedString() and deprecatedInteger()
2168 https://bugs.webkit.org/show_bug.cgi?id=108909
2170 Reviewed by Adam Barth.
2172 By passing an Isolate parameter around, we can reduce usage of
2175 No tests. No change in behavior.
2177 * bindings/scripts/CodeGeneratorV8.pm:
2178 (GenerateNormalAttrSetter):
2179 (GenerateEventListenerCallback):
2180 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2181 (WebCore::TestEventTargetV8Internal::addEventListenerCallback):
2182 (WebCore::TestEventTargetV8Internal::removeEventListenerCallback):
2183 * bindings/scripts/test/V8/V8TestObj.cpp:
2184 (WebCore::TestObjV8Internal::addEventListenerCallback):
2185 (WebCore::TestObjV8Internal::removeEventListenerCallback):
2186 * bindings/v8/IDBBindingUtilities.cpp:
2189 (WebCore::getNthValueOnKeyPath):
2190 (WebCore::canInjectNthValueOnKeyPath):
2191 (WebCore::ensureNthValueOnKeyPath):
2192 (WebCore::createIDBKeyFromScriptValueAndKeyPath):
2193 (WebCore::injectIDBKeyIntoScriptValue):
2194 (WebCore::canInjectIDBKeyIntoScriptValue):
2195 * bindings/v8/NPV8Object.cpp:
2196 (WebCore::createValueListFromVariantArgs):
2198 (_NPN_InvokeDefault):
2201 * bindings/v8/ScriptController.cpp:
2202 (WebCore::ScriptController::compileAndRunScript):
2203 * bindings/v8/ScriptProfiler.cpp:
2205 (WebCore::ScriptProfiler::takeHeapSnapshot):
2206 * bindings/v8/ScriptSourceCode.cpp:
2207 (WebCore::ScriptSourceCode::compileScript):
2208 * bindings/v8/ScriptSourceCode.h:
2210 * bindings/v8/V8LazyEventListener.cpp:
2211 (WebCore::V8LazyEventListener::prepareListenerObject):
2212 * bindings/v8/V8NPObject.cpp:
2213 (WebCore::npObjectInvokeImpl):
2214 (WebCore::npObjectGetProperty):
2215 * bindings/v8/V8NPUtils.cpp:
2216 (WebCore::convertNPVariantToV8Object):
2217 * bindings/v8/V8NPUtils.h:
2219 * bindings/v8/V8Utilities.cpp:
2220 (WebCore::createHiddenDependency):
2221 (WebCore::removeHiddenDependency):
2222 (WebCore::transferHiddenDependency):
2223 * bindings/v8/V8Utilities.h:
2225 * bindings/v8/WorkerScriptController.cpp:
2226 (WebCore::WorkerScriptController::evaluate):
2227 * bindings/v8/custom/V8DOMWindowCustom.cpp:
2228 (WebCore::V8DOMWindow::addEventListenerCallback):
2229 (WebCore::V8DOMWindow::removeEventListenerCallback):
2231 2013-02-05 Kentaro Hara <haraken@chromium.org>
2233 [V8] Make an Isolate parameter mandatory in HasInstance()
2234 https://bugs.webkit.org/show_bug.cgi?id=108917
2236 Reviewed by Adam Barth.
2238 No tests. No change in behavior.
2240 * bindings/scripts/CodeGeneratorV8.pm:
2242 (GenerateImplementation):
2243 * bindings/scripts/test/V8/V8Float64Array.cpp:
2244 (WebCore::V8Float64Array::HasInstance):
2245 * bindings/scripts/test/V8/V8Float64Array.h:
2247 * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2248 (WebCore::V8TestActiveDOMObject::HasInstance):
2249 * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2250 (V8TestActiveDOMObject):
2251 * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2252 (WebCore::V8TestCustomNamedGetter::HasInstance):
2253 * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2254 (V8TestCustomNamedGetter):
2255 * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2256 (WebCore::V8TestEventConstructor::HasInstance):
2257 * bindings/scripts/test/V8/V8TestEventConstructor.h:
2258 (V8TestEventConstructor):
2259 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2260 (WebCore::V8TestEventTarget::HasInstance):
2261 * bindings/scripts/test/V8/V8TestEventTarget.h:
2262 (V8TestEventTarget):
2263 * bindings/scripts/test/V8/V8TestException.cpp:
2264 (WebCore::V8TestException::HasInstance):
2265 * bindings/scripts/test/V8/V8TestException.h:
2267 * bindings/scripts/test/V8/V8TestInterface.cpp:
2268 (WebCore::V8TestInterface::HasInstance):
2269 * bindings/scripts/test/V8/V8TestInterface.h:
2271 * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2272 (WebCore::V8TestMediaQueryListListener::HasInstance):
2273 * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2274 (V8TestMediaQueryListListener):
2275 * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2276 (WebCore::V8TestNamedConstructor::HasInstance):
2277 * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2278 (V8TestNamedConstructor):
2279 * bindings/scripts/test/V8/V8TestNode.cpp:
2280 (WebCore::V8TestNode::HasInstance):
2281 * bindings/scripts/test/V8/V8TestNode.h:
2283 * bindings/scripts/test/V8/V8TestObj.cpp:
2284 (WebCore::V8TestObj::HasInstance):
2285 * bindings/scripts/test/V8/V8TestObj.h:
2287 * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
2288 (WebCore::V8TestOverloadedConstructors::HasInstance):
2289 * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
2290 (V8TestOverloadedConstructors):
2291 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2292 (WebCore::V8TestSerializedScriptValueInterface::HasInstance):
2293 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2294 (V8TestSerializedScriptValueInterface):
2295 * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2296 (WebCore::toWebGLUniformLocation):
2298 2013-02-05 Kentaro Hara <haraken@chromium.org>
2300 [JSC] Clean up CodeGeneratorJS.pm by introducing HasCustom{Getter,Setter,Method}
2301 https://bugs.webkit.org/show_bug.cgi?id=108898
2303 Reviewed by Sam Weinig.
2305 No tests. No change in behavior.
2307 * bindings/scripts/CodeGeneratorJS.pm:
2309 (GenerateImplementation):
2314 2013-02-05 Dana Jansens <danakj@chromium.org>
2316 [chromium] Provide compositor offscreen context through the WebLayerTreeViewClient interface
2317 https://bugs.webkit.org/show_bug.cgi?id=107776
2319 Reviewed by James Robinson.
2321 Allow the compositor thread's context to be retrieved on either thread,
2322 so the main thread can create and pass the context to the impl thread
2323 via its own mechanisms.
2325 Move the code to bind the GrGLInterface to a WebGraphicsContext3D into
2326 chromium's GraphicsContext3DPrivate. The chromium-side code will need
2327 to implement this code itself.
2329 * platform/chromium/support/GraphicsContext3DPrivate.cpp:
2330 (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
2332 (WebCore::GraphicsContext3DPrivate::grContext):
2333 * platform/chromium/support/GraphicsContext3DPrivate.h:
2334 * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
2335 (WebCore::SharedGraphicsContext3D::getForImplThread):
2337 2013-02-05 Tony Gentilcore <tonyg@chromium.org>
2339 Continue making XSSAuditor thread safe: Remove dependency on the parser's tokenizer
2340 https://bugs.webkit.org/show_bug.cgi?id=108666
2342 Reviewed by Adam Barth.
2344 This is the final dependency on the parser, so we remove that as well. Yay!
2346 No new tests because no new functionality.
2348 * html/parser/HTMLDocumentParser.cpp:
2349 (WebCore::HTMLDocumentParser::HTMLDocumentParser):
2350 (WebCore::HTMLDocumentParser::pumpTokenizer): Pass m_tokenizer->shouldAllowCDATA()
2351 * html/parser/XSSAuditor.cpp:
2352 (WebCore::XSSAuditor::XSSAuditor): Remove isMainThread() check because we have one in init() anyway.
2353 Move m_isEnabled and m_documentURL initialization to init() because we have a Document* there.
2354 (WebCore::XSSAuditor::init):
2355 (WebCore::XSSAuditor::filterToken):
2356 (WebCore::XSSAuditor::filterStartToken):
2357 (WebCore::XSSAuditor::filterEndToken):
2358 (WebCore::XSSAuditor::filterScriptToken):
2359 (WebCore::XSSAuditor::decodedSnippetForJavaScript):
2360 * html/parser/XSSAuditor.h:
2361 (WebCore::FilterTokenRequest::FilterTokenRequest):
2362 (FilterTokenRequest):
2365 2013-02-05 Enrica Casucci <enrica@apple.com>
2367 Make baseWritingDirectionForSelectionStart available to all platforms in the Editor class.
2368 https://bugs.webkit.org/show_bug.cgi?id=108977.
2370 Reviewed by Ryosuke Niwa.
2372 Now that baseWritingDirectionForSelectionStart doesn't use
2373 platform specific type anymore, we can make it available for
2374 all platforms. This way it can be used for iOS as well.
2376 No new tests, no functionality change.
2378 * editing/Editor.cpp:
2379 (WebCore::Editor::baseWritingDirectionForSelectionStart): Added.
2380 * editing/Editor.h: Moved from PLATFORM(MAC).
2381 * editing/mac/EditorMac.mm: baseWritingDirectionForSelectionStart removed.
2383 2013-02-05 Benjamin Poulain <bpoulain@apple.com>
2385 Avoid String->AtomicString conversion in Attr::childrenChanged()
2386 https://bugs.webkit.org/show_bug.cgi?id=108742
2388 Reviewed by Andreas Kling.
2391 (WebCore::Attr::childrenChanged): StringBuilder can output AtomicString directly.
2393 2013-02-05 Yusuf Ozuysal <yusufo@google.com>
2395 [chromium] Enable shouldGesturesTriggerActive for Android
2396 https://bugs.webkit.org/show_bug.cgi?id=96948
2398 Reviewed by James Robinson.
2400 We need this to fix performance issues we are getting because of touchstart
2401 triggering hover/active states.
2403 No new tests. The tests introduced in https://bugs.webkit.org/show_bug.cgi?id=96060
2404 should run with the corrected behavior and would cover this change as well.
2406 * page/EventHandler.cpp:
2407 (WebCore::shouldGesturesTriggerActive):
2409 2013-02-05 Mark Lam <mark.lam@apple.com>
2411 Introduced back-end database classes + a few small fixes.
2412 https://bugs.webkit.org/show_bug.cgi?id=108759.
2414 Reviewed by Brady Eidson.
2416 1. Added DatabaseBackendContext, DatabaseBackendAsync, and DatabaseBackendSync.
2417 These are backends for DatabaseContext, Database, and DatabaseSync
2419 2. Added DatabaseBase to hold common code between Database and DatabaseSync.
2420 3. Renamed a few functions.
2421 4. Cleaned up unneeded code in ~DatabaseSync().
2422 5. Added some FIXMEs as reminders or places to clean up when we're done
2424 6. Moved the calling of ScriptController::initializeThreading() from the Database
2425 constructor to DatabaseManager::openDatabase(). This just moves the call
2426 earlier in the same code path. System initialization work (i.e. initializing
2427 script threading in this case) should be done by the manager instead of by
2428 each Database instance.
2433 * GNUmakefile.list.am:
2434 * Modules/webdatabase/AbstractDatabaseServer.h:
2435 (AbstractDatabaseServer):
2436 * Modules/webdatabase/Database.cpp:
2437 (WebCore::Database::Database):
2438 (WebCore::Database::backend):
2439 * Modules/webdatabase/Database.h:
2441 * Modules/webdatabase/DatabaseBackend.cpp:
2442 (WebCore::DatabaseBackend::DatabaseBackend):
2443 (WebCore::DatabaseBackend::~DatabaseBackend):
2444 (WebCore::DatabaseBackend::incrementalVacuumIfNeeded):
2445 * Modules/webdatabase/DatabaseBackend.h:
2447 (WebCore::DatabaseBackend::databaseContext):
2448 (WebCore::DatabaseBackend::setFrontend):
2449 * Modules/webdatabase/DatabaseBackendAsync.cpp: Added.
2450 (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
2451 * Modules/webdatabase/DatabaseBackendAsync.h: Added.
2452 (DatabaseBackendAsync):
2453 * Modules/webdatabase/DatabaseBackendContext.cpp: Added.
2454 (WebCore::DatabaseBackendContext::securityOrigin):
2455 (WebCore::DatabaseBackendContext::isContextThread):
2456 * Modules/webdatabase/DatabaseBackendContext.h: Added.
2457 (DatabaseBackendContext):
2458 (WebCore::DatabaseBackendContext::scriptExecutionContext):
2459 * Modules/webdatabase/DatabaseBackendSync.cpp: Added.
2460 (WebCore::DatabaseBackendSync::DatabaseBackendSync):
2461 (WebCore::DatabaseBackendSync::~DatabaseBackendSync):
2462 * Modules/webdatabase/DatabaseBackendSync.h: Added.
2463 (DatabaseBackendSync):
2464 * Modules/webdatabase/DatabaseBase.cpp: Added.
2465 (WebCore::DatabaseBase::DatabaseBase):
2466 (WebCore::DatabaseBase::scriptExecutionContext):
2467 (WebCore::DatabaseBase::logErrorMessage):
2468 * Modules/webdatabase/DatabaseBase.h: Added.
2470 * Modules/webdatabase/DatabaseContext.cpp:
2471 (WebCore::DatabaseContext::DatabaseContext):
2472 (WebCore::DatabaseContext::backend):
2473 * Modules/webdatabase/DatabaseContext.h:
2475 * Modules/webdatabase/DatabaseManager.cpp:
2476 (WebCore::DatabaseManager::openDatabase):
2477 (WebCore::DatabaseManager::openDatabaseSync):
2478 (WebCore::DatabaseManager::hasOpenDatabases):
2479 (WebCore::DatabaseManager::interruptAllDatabasesForContext):
2480 (WebCore::DatabaseManager::getMaxSizeForDatabase):
2481 (WebCore::DatabaseManager::logErrorMessage):
2482 * Modules/webdatabase/DatabaseManager.h:
2484 * Modules/webdatabase/DatabaseServer.cpp:
2485 (WebCore::DatabaseServer::interruptAllDatabasesForContext):
2486 (WebCore::DatabaseServer::canEstablishDatabase):
2487 * Modules/webdatabase/DatabaseServer.h:
2488 * Modules/webdatabase/DatabaseSync.cpp:
2489 (WebCore::DatabaseSync::DatabaseSync):
2490 (WebCore::DatabaseSync::~DatabaseSync):
2491 (WebCore::DatabaseSync::backend):
2492 * Modules/webdatabase/DatabaseSync.h:
2494 * Modules/webdatabase/DatabaseTracker.cpp:
2495 (WebCore::DatabaseTracker::openTrackerDatabase):
2496 (WebCore::DatabaseTracker::canEstablishDatabase):
2497 (WebCore::DatabaseTracker::hasEntryForDatabase):
2498 (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2499 (WebCore::DatabaseTracker::populateOriginsIfNeeded):
2500 (WebCore::DatabaseTracker::databaseNamesForOriginNoLock):
2501 (WebCore::DatabaseTracker::detailsForNameAndOrigin):
2502 (WebCore::DatabaseTracker::setDatabaseDetails):
2503 (WebCore::DatabaseTracker::usageForOriginNoLock):
2504 (WebCore::DatabaseTracker::setQuota):
2505 (WebCore::DatabaseTracker::addDatabase):
2506 (WebCore::DatabaseTracker::deleteOrigin):
2507 (WebCore::DatabaseTracker::isDeletingDatabaseOrOriginFor):
2508 (WebCore::DatabaseTracker::canDeleteDatabase):
2509 (WebCore::DatabaseTracker::isDeletingDatabase):
2510 (WebCore::DatabaseTracker::canDeleteOrigin):
2511 (WebCore::DatabaseTracker::isDeletingOrigin):
2512 (WebCore::DatabaseTracker::recordDeletingOrigin):
2513 (WebCore::DatabaseTracker::doneDeletingOrigin):
2514 (WebCore::DatabaseTracker::deleteDatabase):
2515 (WebCore::DatabaseTracker::deleteDatabaseFile):
2516 * Modules/webdatabase/DatabaseTracker.h:
2518 * Modules/webdatabase/SQLTransaction.cpp:
2519 * Modules/webdatabase/SQLTransactionClient.cpp:
2520 (WebCore::SQLTransactionClient::didExceedQuota):
2521 * Modules/webdatabase/SQLTransactionSync.cpp:
2522 * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
2523 (WebCore::DatabaseTracker::canEstablishDatabase):
2524 (WebCore::DatabaseTracker::removeOpenDatabase):
2525 (WebCore::DatabaseTracker::prepareToOpenDatabase):
2526 (WebCore::DatabaseTracker::failedToOpenDatabase):
2527 (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2528 (WebCore::DatabaseTracker::closeDatabasesImmediately):
2529 * Modules/webdatabase/chromium/SQLTransactionClientChromium.cpp:
2530 (WebCore::SQLTransactionClient::didCommitWriteTransaction):
2531 (WebCore::SQLTransactionClient::didExceedQuota):
2534 * WebCore.vcproj/WebCore.vcproj:
2535 * WebCore.vcxproj/WebCore.vcxproj:
2536 * WebCore.vcxproj/WebCore.vcxproj.filters:
2537 * WebCore.xcodeproj/project.pbxproj:
2539 2013-02-05 Nayan Kumar K <nayankk@motorola.com>
2541 [WEBGL] Rename WEBKIT_WEBGL_depth_texture to WEBGL_depth_texture.
2542 https://bugs.webkit.org/show_bug.cgi?id=108959
2544 Reviewed by Kenneth Russell.
2546 WEBGL_depth_texture is official now. Hence remove the vendor prefix from
2547 WEBKIT_WEBGL_depth_texture and rename this extension string to WEBGL_depth_texture.
2548 Specification: http://www.khronos.org/registry/webgl/extensions/WEBGL_depth_texture/.
2550 Tests already exists, modified them to test querying of unprefixed extension string.
2552 * bindings/js/JSWebGLRenderingContextCustom.cpp:
2554 * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2555 (WebCore::toV8Object):
2556 * html/canvas/WebGLDepthTexture.cpp:
2557 (WebCore::WebGLDepthTexture::getName):
2558 * html/canvas/WebGLExtension.h:
2559 * html/canvas/WebGLRenderingContext.cpp:
2561 (WebCore::WebGLRenderingContext::getExtension):
2563 2013-02-05 Sheriff Bot <webkit.review.bot@gmail.com>
2565 Unreviewed, rolling out r141905.
2566 http://trac.webkit.org/changeset/141905
2567 https://bugs.webkit.org/show_bug.cgi?id=108963
2569 "Broke mac build" (Requested by tonyg-cr on #webkit).
2571 * html/parser/BackgroundHTMLParser.cpp:
2572 (WebCore::BackgroundHTMLParser::pumpTokenizer):
2573 * html/parser/CompactHTMLToken.cpp:
2574 (SameSizeAsCompactHTMLToken):
2575 (WebCore::isStringSafeToSendToAnotherThread):
2576 (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread):
2577 * html/parser/CompactHTMLToken.h:
2580 * html/parser/HTMLDocumentParser.cpp:
2581 (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
2582 (WebCore::HTMLDocumentParser::pumpTokenizer):
2583 * html/parser/XSSAuditor.cpp:
2584 (WebCore::XSSAuditor::filterToken):
2585 * html/parser/XSSAuditor.h:
2588 * html/parser/XSSAuditorDelegate.cpp:
2589 (WebCore::XSSAuditorDelegate::didBlockScript):
2590 * html/parser/XSSAuditorDelegate.h:
2591 (WebCore::DidBlockScriptRequest::create):
2592 (WebCore::DidBlockScriptRequest::DidBlockScriptRequest):
2593 (XSSAuditorDelegate):
2594 * platform/KURL.cpp:
2597 * platform/KURLGoogle.cpp:
2598 (WebCore::KURLGooglePrivate::reportMemoryUsage):
2599 * platform/KURLGooglePrivate.h:
2600 (KURLGooglePrivate):
2601 * platform/KURLWTFURLImpl.h:
2602 (WebCore::KURLWTFURLImpl::reportMemoryUsage):
2604 2013-02-05 Dominik Röttsches <dominik.rottsches@intel.com>
2606 [HarfBuzz][Cairo] harfBuzzGetGlyph is slow and hot
2607 https://bugs.webkit.org/show_bug.cgi?id=108941
2609 Reviewed by Kenneth Rohde Christiansen.
2611 The text to glyph conversion using Cairo is slow
2612 due to expensive text codec conversion to UTF-8.
2613 Additionally, the glyph lookup itself is expensive.
2615 Inspired by the approach taken in HarfBuzzFaceSkia.cpp
2616 I suggest to implement a similar caching mechanism to
2617 accelerate this conversion.
2619 Arabic line breaking test, under review in
2620 bug 108948 shows about 58% improvement on my system
2623 * platform/graphics/harfbuzz/HarfBuzzFaceCairo.cpp:
2624 (WebCore::HarfBuzzFontData::HarfBuzzFontData):
2625 New container structure that keeps pointers
2626 to the cairo scaled font as well as the glyph cache.
2629 (WebCore::harfBuzzGetGlyph): Using the new container structure for accessing the cache.
2630 (WebCore::harfBuzzGetGlyphHorizontalAdvance): Using the new container structure for accessing the scaled font.
2631 (WebCore::harfBuzzGetGlyphExtents): Ditto.
2632 (WebCore::destroyHarfBuzzFontData): Destroying the container that held the pointers.
2633 (WebCore::HarfBuzzFace::createFont):
2634 Initializing the container structure with the pointers
2635 to the cache that is held in HarfBuzzFace and the cairo scaled font.
2637 2013-02-05 Tony Gentilcore <tonyg@chromium.org>
2639 Call XSSAuditor's didBlockScript() for the threaded HTML parser
2640 https://bugs.webkit.org/show_bug.cgi?id=108726
2642 Reviewed by Adam Barth.
2644 This patch causes us to call didBlockScript() on the main thread if the CompactHTML token has XSSInfo.
2646 1. Rename DidBlockScriptRequest to XSSInfo.
2647 2. Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
2648 3. Add an isSafeToSendToAnotherThread() method to String and KURL.
2650 We don't yet populate didBlockScriptRequest on the background thread, but this should just work once we do.
2652 No new tests because no new functionality.
2654 * html/parser/BackgroundHTMLParser.cpp:
2655 (WebCore::BackgroundHTMLParser::pumpTokenizer): Update comment for rename.
2656 * html/parser/CompactHTMLToken.cpp:
2657 (SameSizeAsCompactHTMLToken):
2658 (WebCore::CompactHTMLToken::CompactHTMLToken): Add a copy constructor used by Vector.
2659 (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread): Include new m_xssInfo field in safety check.
2661 (WebCore::CompactHTMLToken::xssInfo): Added.
2662 (WebCore::CompactHTMLToken::setXSSInfo): Added.
2663 * html/parser/CompactHTMLToken.h: Add an OwnPtr<XSSInfo> field to CompactHTMLToken.
2666 (WTF): Add VectorTraits necessary for copying Vector fields objects that contain an OwnPtr.
2667 * html/parser/HTMLDocumentParser.cpp:
2668 (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser): Add new didBlockScript() call.
2669 (WebCore::HTMLDocumentParser::pumpTokenizer):
2670 * html/parser/XSSAuditor.cpp: Renaming.
2671 (WebCore::XSSAuditor::filterToken):
2672 * html/parser/XSSAuditor.h: Renaming.
2675 * html/parser/XSSAuditorDelegate.cpp:
2676 (WebCore::XSSInfo::isSafeToSendToAnotherThread):
2678 (WebCore::XSSAuditorDelegate::didBlockScript):
2679 * html/parser/XSSAuditorDelegate.h:
2680 (WebCore::XSSInfo::create):
2682 (WebCore::XSSInfo::XSSInfo):
2683 (XSSAuditorDelegate):
2684 * platform/KURL.cpp:
2685 (WebCore::KURL::isSafeToSendToAnotherThread): Added.
2689 * platform/KURLGoogle.cpp:
2691 (WebCore::KURLGooglePrivate::isSafeToSendToAnotherThread): Added.
2692 * platform/KURLGooglePrivate.h:
2693 (KURLGooglePrivate):
2694 * platform/KURLWTFURLImpl.h:
2695 (WebCore::KURLWTFURLImpl::isSafeToSendToAnotherThread): Added.
2697 2013-02-05 Anton Vayvod <avayvod@chromium.org>
2699 TextAutosizing: adjust the maximum difference between cluster text width and its descendant
2701 https://bugs.webkit.org/show_bug.cgi?id=108411
2703 Currently, if a render object is more than 200 CSS units shorter than its parent cluster, it
2704 becomes a separate autosizing cluster (see https://bugs.webkit.org/show_bug.cgi?id=105188).
2705 This doesn't work well for layouts when narrow nodes are related, like nested comments:
2706 deeper comments are all shorter than the parent cluster and become autosized differently. To
2707 avoid that the difference that makes a shorter descendant a new autosizing cluster is
2708 adjusted each time the width difference is not greater than 50 CSS units from the previous
2709 one. This allows nested comments, for example, to remain a part of the parent cluster and be
2710 autosized with the same multiplier.
2712 Reviewed by Kenneth Rohde Christiansen.
2715 fast/text-autosizing/nested-child.html
2717 * rendering/TextAutosizer.cpp:
2718 (WebCore::TextAutosizingClusterInfo::TextAutosizingClusterInfo):
2720 Added a new field to store the current maximum width difference for the cluster.
2722 (WebCore::TextAutosizer::isAutosizingCluster):
2724 Uses the new field to determine if the current node is a separate cluster,
2725 updates the maximum allowed width difference between the cluster and its descendant.
2727 (WebCore::TextAutosizer::processContainer):
2728 (WebCore::TextAutosizer::clusterShouldBeAutosized):
2729 (WebCore::TextAutosizer::measureDescendantTextWidth):
2731 Non-const reference passed to the methods above.
2733 * rendering/TextAutosizer.h: updated method parameters.
2735 2013-02-05 Tony Gentilcore <tonyg@chromium.org>
2737 Continue making XSSAuditor thread safe: Remove dependency on parser's sourceForToken and TextResourceDecoder
2738 https://bugs.webkit.org/show_bug.cgi?id=108698
2740 Reviewed by Adam Barth.
2742 We'd like to be able to call filterToken() from the BackgroundHTMLParser where there is no HTMLDocumentParser. So we are removing the dependencies of
2743 filterToken() on the HTMLDocumentParser. This patch brings us one step closer to removing the m_parser member from XSSAuditor by passing in the
2744 TextResourceDecoder and HTMLSourceTracker to filterToken. To keep the number of parameters from blowing up, this introduces a FilterTokenRequest struct
2745 to hold its arguments. We expect to add one more member to this struct.
2748 No new tests because no new functionality.
2750 * html/parser/HTMLDocumentParser.cpp:
2751 (WebCore::HTMLDocumentParser::pumpTokenizer):
2752 * html/parser/HTMLDocumentParser.h:
2753 * html/parser/XSSAuditor.cpp:
2754 (WebCore::XSSAuditor::filterToken):
2755 (WebCore::XSSAuditor::filterStartToken):
2756 (WebCore::XSSAuditor::filterCharacterToken):
2757 (WebCore::XSSAuditor::filterScriptToken):
2758 (WebCore::XSSAuditor::filterObjectToken):
2759 (WebCore::XSSAuditor::filterParamToken):
2760 (WebCore::XSSAuditor::filterEmbedToken):
2761 (WebCore::XSSAuditor::filterAppletToken):
2762 (WebCore::XSSAuditor::filterIframeToken):
2763 (WebCore::XSSAuditor::filterMetaToken):
2764 (WebCore::XSSAuditor::filterBaseToken):
2765 (WebCore::XSSAuditor::filterFormToken):
2766 (WebCore::XSSAuditor::eraseDangerousAttributesIfInjected):
2767 (WebCore::XSSAuditor::eraseAttributeIfInjected):
2768 (WebCore::XSSAuditor::decodedSnippetForName):
2769 (WebCore::XSSAuditor::decodedSnippetForAttribute):
2770 (WebCore::XSSAuditor::decodedSnippetForJavaScript):
2771 * html/parser/XSSAuditor.h:
2773 (WebCore::FilterTokenRequest::FilterTokenRequest):
2774 (FilterTokenRequest):
2777 2013-02-05 Jocelyn Turcotte <jocelyn.turcotte@digia.com>
2779 [Qt] REGRESSION(r137436): It made all inspector tests timeout on developer builds
2780 https://bugs.webkit.org/show_bug.cgi?id=106554
2782 Reviewed by Simon Hausmann.
2786 2013-02-05 Peter Rybin <prybin@chromium.org>
2788 Web Inspector: prevent crash, add required error string value
2789 https://bugs.webkit.org/show_bug.cgi?id=108776
2791 Reviewed by Pavel Feldman.
2793 Error string is assigned where missing, assert is added where empty string is
2796 * inspector/InjectedScriptBase.cpp:
2797 (WebCore::InjectedScriptBase::makeEvalCall):
2798 * inspector/PageRuntimeAgent.cpp:
2799 (WebCore::PageRuntimeAgent::injectedScriptForEval):
2801 2013-02-05 Eugene Klyuchnikov <eustas@chromium.org>
2803 Web Inspector: Clicking a profile's title in the console loads about:blank.
2804 https://bugs.webkit.org/show_bug.cgi?id=107949
2806 Reviewed by Vsevolod Vlasov.
2808 Quick fix for regression.
2810 * inspector/front-end/inspector.js:
2811 Avoid "exit route" when URL is a profile URL.
2813 2013-02-05 Kent Tamura <tkent@chromium.org>
2815 INPUT_MULTIPLE_FIELDS_UI: element.focus() should not focus on disabled sub-fields.
2816 https://bugs.webkit.org/show_bug.cgi?id=108924
2818 Reviewed by Kentaro Hara.
2820 The first field may be non-focusable. We should search sub-fields for
2823 Test: fast/forms/date-multiple-fields/date-multiple-fields-focus.html
2825 * html/shadow/DateTimeEditElement.cpp:
2826 (WebCore::DateTimeEditElement::focusOnNextFocusableField):
2827 Added. A private helper function.
2828 (WebCore::DateTimeEditElement::focusIfNoFocus): Use focusOnNextFocusableField.
2829 (WebCore::DateTimeEditElement::focusByOwner): Ditto.
2830 (WebCore::DateTimeEditElement::focusOnNextField): Ditto.
2831 * html/shadow/DateTimeEditElement.h:
2832 (DateTimeEditElement): Declare focusOnNextFocusableField.
2834 2013-02-04 Vsevolod Vlasov <vsevik@chromium.org>
2836 Web Inspector: Create separate project for each file system added to inspector.
2837 https://bugs.webkit.org/show_bug.cgi?id=108652
2839 Reviewed by Pavel Feldman.
2841 Every file system added to web inspector is now represented by its own project in workspace.
2842 FileSystemMapping changed accrodingly.
2844 Test: inspector/file-system-mapping.html
2846 * inspector/front-end/FileMapping.js:
2847 (WebInspector.FileMapping.prototype._entryURIPrefix):
2848 * inspector/front-end/FileSystemMapping.js:
2849 (WebInspector.FileSystemMapping.prototype.fileForURI):
2850 (WebInspector.FileSystemMapping.prototype.uriForFile):
2851 (WebInspector.FileSystemMapping.prototype.uriPrefixForPathPrefix):
2852 (WebInspector.FileSystemMappingImpl):
2853 (WebInspector.FileSystemMappingImpl.prototype._loadFromSettings.get this):
2854 (WebInspector.FileSystemMappingImpl.prototype._loadFromSettings):
2855 (WebInspector.FileSystemMappingImpl.prototype._saveToSettings):
2856 (WebInspector.FileSystemMappingImpl.prototype.set _fileSystemName):
2857 (WebInspector.FileSystemMappingImpl.prototype.fileSystemId):
2858 (WebInspector.FileSystemMappingImpl.prototype.addFileSystemMapping):
2859 (WebInspector.FileSystemMappingImpl.prototype.removeFileSystemMapping):
2860 (WebInspector.FileSystemMappingImpl.prototype.fileSystemPaths):
2861 (WebInspector.FileSystemMappingImpl.prototype.fileForURI):
2862 (WebInspector.FileSystemMappingImpl.prototype.uriForFile):
2863 (WebInspector.FileSystemMappingImpl.prototype.uriPrefixForPathPrefix):
2864 * inspector/front-end/FileSystemWorkspaceProvider.js:
2865 (WebInspector.FileSystemWorkspaceProvider):
2866 (WebInspector.FileSystemWorkspaceProvider.prototype.innerCallback):
2867 (WebInspector.FileSystemWorkspaceProvider.prototype.requestFileContent):
2868 (WebInspector.FileSystemWorkspaceProvider.prototype.setFileContent):
2869 (WebInspector.FileSystemWorkspaceProvider.prototype._populate.filesLoaded):
2870 (WebInspector.FileSystemWorkspaceProvider.prototype._populate):
2871 (WebInspector.FileSystemWorkspaceProvider.prototype._addFile):
2872 (WebInspector.FileSystemWorkspaceProvider.prototype._removeFile):
2873 (WebInspector.FileSystemWorkspaceProvider.prototype.reset):
2874 * inspector/front-end/IsolatedFileSystemModel.js:
2875 (WebInspector.IsolatedFileSystemModel):
2876 (WebInspector.IsolatedFileSystemModel.prototype._innerAddFileSystem):
2877 (WebInspector.IsolatedFileSystemModel.prototype._fileSystemRemoved):
2878 * inspector/front-end/Workspace.js:
2879 (WebInspector.Project.prototype.searchInFileContent):
2880 (WebInspector.Project.prototype.dispose):
2881 (WebInspector.Workspace.prototype.removeProject):
2883 2013-02-05 Kent Tamura <tkent@chromium.org>
2885 INPUT_MULTIPLE_FIELDS_UI: Should not move focus if the element already has focus
2886 https://bugs.webkit.org/show_bug.cgi?id=108914
2888 Reviewed by Kentaro Hara.
2890 If timeInput.focus() is called when a sub-field of the time input
2891 already has focus, we should not focus on the first sub-field of the
2894 Test: fast/forms/time-multiple-fields/time-multiple-fields-focus.html
2896 * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
2897 (WebCore::BaseMultipleFieldsDateAndTimeInputType::willCancelFocus): If
2898 the input elment already has focused sub-field, we don't need to proceed
2899 focus handling. FocusDirection check is required because we don't need
2900 to do this in cases of sequential focus navigation.
2901 * html/BaseMultipleFieldsDateAndTimeInputType.h:
2902 (BaseMultipleFieldsDateAndTimeInputType): Override InputType::willCancelFocus.
2904 * html/HTMLInputElement.cpp:
2905 (WebCore::HTMLInputElement::focus):
2906 Cancel focus if InputType::willCancelFocus returns true.
2907 * html/HTMLInputElement.h:
2908 (HTMLInputElement): Override focus.
2909 * html/InputType.cpp:
2910 (WebCore::InputType::willCancelFocus):
2911 Add a default implementation. It returns false.
2913 (InputType): Declare willCancelFocus.
2915 2013-02-05 Allan Sandfeld Jensen <allan.jensen@digia.com>
2917 [Qt] RGB -> BGR is wrong on big endian
2918 https://bugs.webkit.org/show_bug.cgi?id=107560
2920 Reviewed by Jocelyn Turcotte.
2922 Replace the conversion to methods that make it clearer what is going on.
2923 The routines are also optimized compared to the existing by avoiding going
2924 over slow Color constructor.
2926 Tested by existing tests in canvas and fast/canvas.
2928 * platform/graphics/Color.cpp:
2929 (WebCore::colorFromPremultipliedARGB):
2931 (WebCore::premultipliedARGBFromColor):
2932 Cleanup and correct for alpha = 0.
2933 * platform/graphics/Color.h:
2935 * platform/graphics/qt/ImageBufferQt.cpp:
2936 (WebCore::copyColorToRGBA):
2937 (WebCore::copyRGBAToColor):
2938 (WebCore::getImageData):
2939 (WebCore::ImageBuffer::putByteArray):
2941 2013-02-05 JungJik Lee <jungjik.lee@samsung.com>
2943 [TexMap] Use visible as initial value of backface-visibility-property.
2944 https://bugs.webkit.org/show_bug.cgi?id=108875
2946 Reviewed by Noam Rosenthal.
2948 According to W3C spec, the initial value of backface-visibility-visibility is visible.
2949 However TextureMapperLayer's initial value is false which means hidden.
2950 So this patch is for changing the value to visible(true).
2952 Covered by existing tests.
2954 * platform/graphics/texmap/TextureMapperLayer.h:
2955 (WebCore::TextureMapperLayer::State::State): Change the initial value false to true
2956 to use backface-visibility.
2958 2013-02-05 Andrey Adaikin <aandrey@chromium.org>
2960 Web Inspector: [Canvas] do not store a dropped trace log in backend
2961 https://bugs.webkit.org/show_bug.cgi?id=108600
2963 Reviewed by Pavel Feldman.
2965 Clear memory immediately on dropping current trace log instead of waiting for the next capture command.
2967 * inspector/InjectedScriptCanvasModuleSource.js:
2970 2013-02-05 Andrey Adaikin <aandrey@chromium.org>
2972 Web Inspector: [Canvas] UI is not restored properly when deleting a live recording profile
2973 https://bugs.webkit.org/show_bug.cgi?id=108602
2975 Reviewed by Pavel Feldman.
2977 Cancel recording profile of canvas-type when deleting an alive trace log.
2978 Drive-by: rename ProfileHeader.reset to ProfileHeader.dispose since it's called on header's destruction.
2980 * inspector/front-end/CanvasProfileView.js:
2981 (WebInspector.CanvasProfileHeader.prototype.dispose):
2982 * inspector/front-end/ProfilesPanel.js:
2983 (WebInspector.ProfileHeader.prototype.dispose):
2984 (WebInspector.ProfilesPanel.prototype._reset):
2985 (WebInspector.ProfilesPanel.prototype._removeProfileHeader):
2986 (WebInspector.ProfilesPanel.prototype.setRecordingProfile):
2988 2013-02-05 Julien Brianceau <jbrianceau@nds.com>
2990 Build is broken since r141543 for platforms without OpenGL
2991 https://bugs.webkit.org/show_bug.cgi?id=108862
2993 Reviewed by Simon Hausmann.
2997 2013-02-05 Kentaro Hara <haraken@chromium.org>
2999 Unreviewed, rolling out r141865.
3000 http://trac.webkit.org/changeset/141865
3001 https://bugs.webkit.org/show_bug.cgi?id=108909
3003 webkit unit tests are broken
3005 * bindings/scripts/CodeGeneratorV8.pm:
3006 (GenerateNormalAttrSetter):
3007 (GenerateEventListenerCallback):
3008 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3009 (WebCore::TestEventTargetV8Internal::addEventListenerCallback):
3010 (WebCore::TestEventTargetV8Internal::removeEventListenerCallback):
3011 * bindings/scripts/test/V8/V8TestObj.cpp:
3012 (WebCore::TestObjV8Internal::addEventListenerCallback):
3013 (WebCore::TestObjV8Internal::removeEventListenerCallback):
3014 * bindings/v8/IDBBindingUtilities.cpp:
3017 (WebCore::getNthValueOnKeyPath):
3018 (WebCore::canInjectNthValueOnKeyPath):
3019 (WebCore::ensureNthValueOnKeyPath):
3020 (WebCore::createIDBKeyFromScriptValueAndKeyPath):
3021 (WebCore::injectIDBKeyIntoScriptValue):
3022 (WebCore::canInjectIDBKeyIntoScriptValue):
3023 * bindings/v8/NPV8Object.cpp:
3024 (WebCore::createValueListFromVariantArgs):
3026 (_NPN_InvokeDefault):
3029 * bindings/v8/ScriptController.cpp:
3030 (WebCore::ScriptController::compileAndRunScript):
3031 * bindings/v8/ScriptProfiler.cpp:
3032 (WebCore::ScriptProfiler::takeHeapSnapshot):
3033 * bindings/v8/ScriptSourceCode.cpp:
3034 (WebCore::ScriptSourceCode::compileScript):
3035 * bindings/v8/ScriptSourceCode.h:
3037 * bindings/v8/V8LazyEventListener.cpp:
3038 (WebCore::V8LazyEventListener::prepareListenerObject):
3039 * bindings/v8/V8NPObject.cpp:
3040 (WebCore::npObjectInvokeImpl):
3041 (WebCore::npObjectGetProperty):
3042 * bindings/v8/V8NPUtils.cpp:
3043 (WebCore::convertNPVariantToV8Object):
3044 * bindings/v8/V8NPUtils.h:
3046 * bindings/v8/V8Utilities.cpp:
3047 (WebCore::createHiddenDependency):
3048 (WebCore::removeHiddenDependency):
3049 (WebCore::transferHiddenDependency):
3050 * bindings/v8/V8Utilities.h:
3052 * bindings/v8/WorkerScriptController.cpp:
3053 (WebCore::WorkerScriptController::evaluate):
3054 * bindings/v8/custom/V8DOMWindowCustom.cpp:
3055 (WebCore::V8DOMWindow::addEventListenerCallback):
3056 (WebCore::V8DOMWindow::removeEventListenerCallback):
3058 2013-02-05 Mike West <mkwst@chromium.org>
3060 Cleanup: Use exceptionless Range::* methods rather than ignoring exceptions.
3061 https://bugs.webkit.org/show_bug.cgi?id=108773
3063 Reviewed by Darin Adler.
3065 We often call Range::{start,end}{Container,Offset} with an ExceptionCode
3066 that's completely ignored. In these cases, we should simply use the
3067 exceptionless version of the method instead.
3069 * dom/DocumentMarkerController.cpp:
3070 (WebCore::DocumentMarkerController::addMarker):
3071 Here, I also moved parameters onto one line to make the
3073 (WebCore::DocumentMarkerController::addTextMatchMarker):
3074 (WebCore::DocumentMarkerController::setMarkersActive):
3075 Dropped ignored ExceptionCode variable entirely.
3076 * accessibility/AccessibilityRenderObject.cpp:
3077 (WebCore::AccessibilityRenderObject::visiblePositionForIndex):
3078 Can't drop the variable because of the selectNodeContents call.
3079 * editing/Editor.cpp:
3080 (WebCore::Editor::canDeleteRange):
3081 Dropped ignored ExceptionCode variable entirely.
3082 (WebCore::Editor::advanceToNextMisspelling):
3083 Can't drop the variable because of setStart/setEnd.
3084 * editing/EditorCommand.cpp:
3085 (WebCore::unionDOMRanges):
3086 Can't drop the variable because of compareBoundaryPoints.
3087 * editing/MarkupAccumulator.cpp:
3088 (WebCore::MarkupAccumulator::appendNodeValue):
3089 Dropped ignored ExceptionCode variable entirely.
3090 * editing/TextCheckingHelper.cpp:
3091 (WebCore::TextCheckingParagraph::offsetAsRange):
3092 (WebCore::TextCheckingHelper::findFirstMisspelling):
3093 (WebCore::TextCheckingHelper::findFirstGrammarDetail):
3094 (WebCore::TextCheckingHelper::findFirstMisspellingOrBadGrammar):
3095 * editing/markup.cpp:
3096 (WebCore::StyledMarkupAccumulator::renderedText):
3097 (WebCore::StyledMarkupAccumulator::stringValueForRange):
3098 Dropped ignored ExceptionCode variable entirely.
3099 * editing/visible_units.cpp:
3100 (WebCore::previousBoundary):
3101 Can't drop the variable due to many other calls.
3102 * page/DOMSelection.cpp:
3103 (WebCore::DOMSelection::deleteFromDocument):
3104 (WebCore::DOMSelection::containsNode):
3105 For both these cases, the 'ASSERT(!ec)' after the statement I've
3106 edited only checked the last occurance of the exception: that is,
3107 if 'startXxx(ec)' threw an exception, it would be overwritten by
3108 the 'setBaseAndExtend()' or 'compareBoundaryPoints()' exception.
3109 Removing the exception parameters from the parameters' calls
3110 shouldn't effect behavior.
3111 * platform/chromium/PasteboardChromium.cpp:
3112 (WebCore::Pasteboard::writeSelection):
3113 * platform/mac/HTMLConverter.mm:
3114 (+[WebHTMLConverter editingAttributedStringFromRange:]):
3115 * platform/win/ClipboardWin.cpp:
3116 (WebCore::ClipboardWin::writeRange):
3117 * platform/win/PasteboardWin.cpp:
3118 (WebCore::Pasteboard::writeSelection):
3119 * platform/wince/PasteboardWinCE.cpp:
3120 (WebCore::Pasteboard::writeSelection):
3121 Dropped ignored ExceptionCode variable entirely.
3123 2013-02-05 Yury Semikhatsky <yurys@chromium.org>
3125 Web Inspector: introduce Memory.getDOMCounters
3126 https://bugs.webkit.org/show_bug.cgi?id=108822
3128 Reviewed by Pavel Feldman.
3130 Introduced Memory.getDOMCounters command that returns number of Documents, Nodes
3131 and JS event listeners in the inspected process.
3133 * inspector/Inspector.json:
3134 * inspector/InspectorMemoryAgent.cpp:
3135 (WebCore::InspectorMemoryAgent::getDOMCounters):
3137 * inspector/InspectorMemoryAgent.h:
3138 (InspectorMemoryAgent):
3140 2013-02-04 Ilya Tikhonovsky <loislo@chromium.org>
3142 Web Inspector: Native Memory Instrumentation: rename Image m_data member to m_encodedImageData for the consistency
3143 https://bugs.webkit.org/show_bug.cgi?id=108913
3145 Reviewed by Yury Semikhatsky.
3147 No new tests because no API changes.
3149 * platform/graphics/Image.cpp:
3150 (WebCore::Image::setData):
3151 (WebCore::Image::reportMemoryUsage):
3152 * platform/graphics/Image.h:
3153 (WebCore::Image::data):
3156 2013-02-05 Hajime Morrita <morrita@google.com>
3158 Unreviewed Linux ASAN build fix for r141783.
3160 * platform/RefCountedSupplement.h:
3162 * platform/Supplementable.h:
3165 2013-02-05 Mike West <mkwst@chromium.org>
3167 [chromium] Unreviewed: Fix broken SVG-disabled build.
3168 https://bugs.webkit.org/show_bug.cgi?id=108916
3170 The new enum value CSSPropertyWebkitGridAutoFlow was introduced in
3171 r141787, and accidentally left out of CSSParser::parseValue's big
3172 switch. This causes problems in non-SVG builds.
3174 * css/CSSParser.cpp:
3175 (WebCore::CSSParser::parseValue):
3177 2013-02-05 Tommy Widenflycht <tommyw@google.com>
3179 MediaStream API: Update RTCPeerConnections stream accessors to match the latest specification
3180 https://bugs.webkit.org/show_bug.cgi?id=108179
3182 Reviewed by Adam Barth.
3184 http://dev.w3.org/2011/webrtc/editor/webrtc.html#interface-definition
3185 The attributes localStreams and remoteStreams have been changes to the methods
3186 getLocalStreams() and getRemoteStreams() which return a native array instead.
3188 Existing tests updated to cover patch.
3191 * GNUmakefile.list.am:
3192 * Modules/mediastream/MediaStream.h:
3194 * Modules/mediastream/MediaStreamList.cpp: Removed.
3195 * Modules/mediastream/MediaStreamList.h: Removed.
3196 * Modules/mediastream/MediaStreamList.idl: Removed.
3197 * Modules/mediastream/RTCPeerConnection.cpp:
3198 (WebCore::RTCPeerConnection::RTCPeerConnection):
3199 (WebCore::RTCPeerConnection::addStream):
3200 (WebCore::RTCPeerConnection::removeStream):
3201 (WebCore::RTCPeerConnection::getLocalStreams):
3202 (WebCore::RTCPeerConnection::getRemoteStreams):
3203 (WebCore::RTCPeerConnection::didAddRemoteStream):
3204 (WebCore::RTCPeerConnection::didRemoveRemoteStream):
3205 * Modules/mediastream/RTCPeerConnection.h:
3206 (RTCPeerConnection):
3207 * Modules/mediastream/RTCPeerConnection.idl:
3210 2013-02-05 Viatcheslav Ostapenko <sl.ostapenko@samsung.com>
3212 [Qt][EFL][WebGL] Webgl doesn't work on nvidia cards
3213 https://bugs.webkit.org/show_bug.cgi?id=108059
3215 Reviewed by Kenneth Rohde Christiansen.
3217 Commit r138327 fixed repainting issues on mesa3d GL library by re-binding
3218 texture to the window after every glXSwapBuffer. Unfortunatelly re-bind
3219 breaks rendering on NVidia cards with NVidia propiertary drivers.
3220 This change limits texture re-binding only for mesa3d GL library.
3222 No new tests. HW specific fix.
3224 * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp:
3225 (WebCore::OffScreenRootWindow::isMesaGLX):
3226 (OffScreenRootWindow):
3227 (WebCore::GraphicsSurface::platformSwapBuffers):
3229 2013-02-05 Praveen Jadhav <praveen.j@samsung.com>
3231 Floating point precision error in AudioPannerNode.
3232 https://bugs.webkit.org/show_bug.cgi?id=106001
3234 Reviewed by Kentaro Hara.
3236 Specifications Update:
3237 https://dvcs.w3.org/hg/audio/rev/69a39a516e45
3239 Conversion from double to float and back to double
3240 results in precision error. Avoiding these conversions
3241 will make sure that proper values are retained in the
3244 * Modules/webaudio/PannerNode.h:
3245 (WebCore::PannerNode::refDistance):
3246 (WebCore::PannerNode::setRefDistance):
3247 (WebCore::PannerNode::maxDistance):
3248 (WebCore::PannerNode::setMaxDistance):
3249 (WebCore::PannerNode::rolloffFactor):
3250 (WebCore::PannerNode::setRolloffFactor):
3251 (WebCore::PannerNode::coneInnerAngle):
3252 (WebCore::PannerNode::setConeInnerAngle):
3253 (WebCore::PannerNode::coneOuterAngle):
3254 (WebCore::PannerNode::setConeOuterAngle):
3255 (WebCore::PannerNode::coneOuterGain):
3256 (WebCore::PannerNode::setConeOuterGain):
3257 * Modules/webaudio/PannerNode.idl:
3259 2013-02-05 Kent Tamura <tkent@chromium.org>
3261 INPUT_MULTIPLE_FIELDS_UI: Use disabled attribute internally instead of readonly attribute
3262 https://bugs.webkit.org/show_bug.cgi?id=108911
3264 Reviewed by Kentaro Hara.
3266 Use 'disabled' attribute for shadow elements for <input> with
3267 multiple-fields UI instead of 'readonly' attribute because 'readonly'
3268 attribute represents focusable-but-non-editable state in HTML though
3269 we'd like to represent non-focusable-and-non-editable state.
3271 The summary of changes:
3272 - Use 'disabled' attribute instead of 'readonly' attribute for DateTimeFieldElement,
3273 - Rename C++ functions for it,
3274 - Call isFocusable instead of isReadOnly to check focusable state.
3276 No new tests. This doesn't make user-visible behavior changes.
3279 Replace [readonly] with [disabled] for sub-fields.
3280 * html/shadow/DateTimeEditElement.cpp:
3281 (DateTimeEditBuilder):
3282 (WebCore::DateTimeEditBuilder::visitField):
3283 (WebCore::DateTimeEditBuilder::shouldDayOfMonthFieldDisabled):
3284 (WebCore::DateTimeEditBuilder::shouldHourFieldDisabled):
3285 (WebCore::DateTimeEditBuilder::shouldMillisecondFieldDisabled):
3286 (WebCore::DateTimeEditBuilder::shouldMinuteFieldDisabled):
3287 (WebCore::DateTimeEditBuilder::shouldSecondFieldDisabled):
3288 (WebCore::DateTimeEditBuilder::shouldYearFieldDisabled):
3289 (WebCore::DateTimeEditElement::anyEditableFieldsHaveValues):
3290 (WebCore::DateTimeEditElement::focusOnNextField): Use isFocusable.
3291 (WebCore::DateTimeEditElement::focusOnPreviousField): Use isFocusable.
3292 * html/shadow/DateTimeFieldElement.cpp:
3293 (WebCore::DateTimeFieldElement::isFocusable):
3294 (WebCore::DateTimeFieldElement::isDisabled):
3295 (WebCore::DateTimeFieldElement::setDisabled):
3296 * html/shadow/DateTimeFieldElement.h:
3297 (DateTimeFieldElement): Make isFocusable public in order that
3298 DateTimeEditElement can call it.
3299 * html/shadow/DateTimeNumericFieldElement.cpp:
3300 (WebCore::DateTimeNumericFieldElement::handleKeyboardEvent):
3301 (WebCore::DateTimeNumericFieldElement::setEmptyValue):
3302 * html/shadow/DateTimeSymbolicFieldElement.cpp:
3303 (WebCore::DateTimeSymbolicFieldElement::setEmptyValue):
3305 2013-02-05 Kentaro Hara <haraken@chromium.org>
3307 [V8] Reduce usage of deprecatedString() and deprecatedInteger()
3308 https://bugs.webkit.org/show_bug.cgi?id=108909
3310 Reviewed by Adam Barth.
3312 By passing an Isolate parameter around, we can reduce usage of
3315 No tests. No change in behavior.
3317 * bindings/scripts/CodeGeneratorV8.pm:
3318 (GenerateNormalAttrSetter):
3319 (GenerateEventListenerCallback):
3320 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3321 (WebCore::TestEventTargetV8Internal::addEventListenerCallback):
3322 (WebCore::TestEventTargetV8Internal::removeEventListenerCallback):
3323 * bindings/scripts/test/V8/V8TestObj.cpp:
3324 (WebCore::TestObjV8Internal::addEventListenerCallback):
3325 (WebCore::TestObjV8Internal::removeEventListenerCallback):
3326 * bindings/v8/IDBBindingUtilities.cpp:
3329 (WebCore::getNthValueOnKeyPath):
3330 (WebCore::canInjectNthValueOnKeyPath):
3331 (WebCore::ensureNthValueOnKeyPath):
3332 (WebCore::createIDBKeyFromScriptValueAndKeyPath):
3333 (WebCore::injectIDBKeyIntoScriptValue):
3334 (WebCore::canInjectIDBKeyIntoScriptValue):
3335 * bindings/v8/NPV8Object.cpp:
3336 (WebCore::createValueListFromVariantArgs):
3338 (_NPN_InvokeDefault):
3341 * bindings/v8/ScriptController.cpp:
3342 (WebCore::ScriptController::compileAndRunScript):
3343 * bindings/v8/ScriptProfiler.cpp:
3345 (WebCore::ScriptProfiler::takeHeapSnapshot):
3346 * bindings/v8/ScriptSourceCode.cpp:
3347 (WebCore::ScriptSourceCode::compileScript):
3348 * bindings/v8/ScriptSourceCode.h:
3350 * bindings/v8/V8LazyEventListener.cpp:
3351 (WebCore::V8LazyEventListener::prepareListenerObject):
3352 * bindings/v8/V8NPObject.cpp:
3353 (WebCore::npObjectInvokeImpl):
3354 (WebCore::npObjectGetProperty):
3355 * bindings/v8/V8NPUtils.cpp:
3356 (WebCore::convertNPVariantToV8Object):
3357 * bindings/v8/V8NPUtils.h:
3359 * bindings/v8/V8Utilities.cpp:
3360 (WebCore::createHiddenDependency):
3361 (WebCore::removeHiddenDependency):
3362 (WebCore::transferHiddenDependency):
3363 * bindings/v8/V8Utilities.h:
3365 * bindings/v8/WorkerScriptController.cpp:
3366 (WebCore::WorkerScriptController::evaluate):
3367 * bindings/v8/custom/V8DOMWindowCustom.cpp:
3368 (WebCore::V8DOMWindow::addEventListenerCallback):
3369 (WebCore::V8DOMWindow::removeEventListenerCallback):
3371 2013-02-04 Dean Jackson <dino@apple.com>
3373 [Mac] Captions menu should indicate language and type of track
3374 https://bugs.webkit.org/show_bug.cgi?id=108882
3376 Reviewed by Eric Carlson.
3378 On Mac, we want a specific format for menu items in a caption list. Since
3379 other ports might want different formats, move the generation of the label
3380 into CaptionsUserPreferences where it can be overridden.
3382 This required CaptionsUserPreferences to become public on the PageGroup, so
3383 it could be used when creating the menu. Also, since CaptionsUserPreferences
3384 was hidden on Mountain Lion and below, be a little more specific about
3385 which pieces can be seen on which builds.
3387 Covered by exisiting media/video-controls-captions-trackmenu tests.
3389 * English.lproj/Localizable.strings: Remove textTrackClosedCaptionsText.
3390 * html/shadow/MediaControlElements.cpp:
3391 (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu): Build only
3392 one section and get the track's display name from the user preferences.
3393 * page/CaptionUserPreferences.h:
3394 (WebCore::CaptionUserPreferences::displayNameForTrack): Default implementation of
3395 virtual function that provides a label for a captions menu item.
3396 * page/CaptionUserPreferencesMac.h: Add the new virtual function, and expose just
3397 a bit of this class outside 10.9 builds.
3398 * page/CaptionUserPreferencesMac.mm:
3399 (WebCore::CaptionUserPreferencesMac::CaptionUserPreferencesMac): Guard features for system version.
3400 (WebCore::CaptionUserPreferencesMac::~CaptionUserPreferencesMac): Ditto.
3401 (WebCore::CaptionUserPreferencesMac::displayNameForTrack): New OS X-specific method that
3402 returns a string for the menu label.
3403 * page/PageGroup.cpp:
3404 (WebCore::PageGroup::captionPreferences): Unguard for system version.
3405 * page/PageGroup.h: Make captionPreferences public.
3406 * platform/LocalizedStrings.cpp: Remove textTrackClosedCaptionsText - not needed any more.
3407 * platform/LocalizedStrings.h: Remove textTrackClosedCaptionsText.
3409 2013-02-04 Kentaro Hara <haraken@chromium.org>
3411 [V8] Pass an Isolate to V8DOMConfiguration
3412 https://bugs.webkit.org/show_bug.cgi?id=108900
3414 Reviewed by Adam Barth.
3416 No tests. No change in behavior.
3418 * bindings/scripts/CodeGeneratorV8.pm:
3420 (GenerateImplementation):
3421 (GenerateToV8Converters):
3422 * bindings/scripts/test/V8/V8Float64Array.cpp:
3423 (WebCore::ConfigureV8Float64ArrayTemplate):
3424 (WebCore::V8Float64Array::createWrapper):
3425 * bindings/scripts/test/V8/V8Float64Array.h:
3426 (WebCore::V8Float64Array::installPerContextProperties):
3427 * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
3428 (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
3429 (WebCore::V8TestActiveDOMObject::createWrapper):
3430 * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
3431 (WebCore::V8TestActiveDOMObject::installPerContextProperties):
3432 * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
3433 (WebCore::ConfigureV8TestCustomNamedGetterTemplate):
3434 (WebCore::V8TestCustomNamedGetter::createWrapper):
3435 * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
3436 (WebCore::V8TestCustomNamedGetter::installPerContextProperties):
3437 * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
3438 (WebCore::ConfigureV8TestEventConstructorTemplate):
3439 (WebCore::V8TestEventConstructor::createWrapper):
3440 * bindings/scripts/test/V8/V8TestEventConstructor.h:
3441 (WebCore::V8TestEventConstructor::installPerContextProperties):
3442 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3443 (WebCore::ConfigureV8TestEventTargetTemplate):
3444 (WebCore::V8TestEventTarget::createWrapper):
3445 * bindings/scripts/test/V8/V8TestEventTarget.h:
3446 (WebCore::V8TestEventTarget::installPerContextProperties):
3447 * bindings/scripts/test/V8/V8TestException.cpp:
3448 (WebCore::ConfigureV8TestExceptionTemplate):
3449 (WebCore::V8TestException::createWrapper):
3450 * bindings/scripts/test/V8/V8TestException.h:
3451 (WebCore::V8TestException::installPerContextProperties):
3452 * bindings/scripts/test/V8/V8TestInterface.cpp:
3453 (WebCore::ConfigureV8TestInterfaceTemplate):
3454 (WebCore::V8TestInterface::createWrapper):
3455 * bindings/scripts/test/V8/V8TestInterface.h:
3456 (WebCore::V8TestInterface::installPerContextProperties):
3457 * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
3458 (WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
3459 (WebCore::V8TestMediaQueryListListener::createWrapper):
3460 * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
3461 (WebCore::V8TestMediaQueryListListener::installPerContextProperties):
3462 * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
3463 (WebCore::ConfigureV8TestNamedConstructorTemplate):
3464 (WebCore::V8TestNamedConstructor::createWrapper):
3465 * bindings/scripts/test/V8/V8TestNamedConstructor.h:
3466 (WebCore::V8TestNamedConstructor::installPerContextProperties):
3467 * bindings/scripts/test/V8/V8TestNode.cpp:
3468 (WebCore::ConfigureV8TestNodeTemplate):
3469 (WebCore::V8TestNode::createWrapper):
3470 * bindings/scripts/test/V8/V8TestNode.h:
3471 (WebCore::V8TestNode::installPerContextProperties):
3472 * bindings/scripts/test/V8/V8TestObj.cpp:
3473 (WebCore::ConfigureV8TestObjTemplate):
3474 (WebCore::V8TestObj::installPerContextProperties):
3475 (WebCore::V8TestObj::createWrapper):
3476 * bindings/scripts/test/V8/V8TestObj.h:
3478 * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
3479 (WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
3480 (WebCore::V8TestOverloadedConstructors::createWrapper):
3481 * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
3482 (WebCore::V8TestOverloadedConstructors::installPerContextProperties):
3483 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3484 (WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
3485 (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
3486 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
3487 (WebCore::V8TestSerializedScriptValueInterface::installPerContextProperties):
3488 * bindings/v8/V8DOMConfiguration.cpp:
3489 (WebCore::V8DOMConfiguration::batchConfigureAttributes):
3490 (WebCore::V8DOMConfiguration::batchConfigureConstants):
3491 (WebCore::V8DOMConfiguration::batchConfigureCallbacks):
3492 (WebCore::V8DOMConfiguration::configureTemplate):
3493 * bindings/v8/V8DOMConfiguration.h:
3494 (V8DOMConfiguration):
3495 (WebCore::V8DOMConfiguration::configureAttribute):
3496 * bindings/v8/V8DOMWindowShell.cpp:
3497 (WebCore::V8DOMWindowShell::installDOMWindow):
3499 2013-02-04 Kentaro Hara <haraken@chromium.org>
3501 [V8] Clean up CodeGeneratorV8.pm by introducing HasCustom{Getter,Setter,Method}
3502 https://bugs.webkit.org/show_bug.cgi?id=108896
3504 Reviewed by Adam Barth.
3506 No tests. No change in generated code.
3508 * bindings/scripts/CodeGeneratorV8.pm:
3513 (GetFunctionTemplateCallbackName):
3514 (GenerateSingleBatchedAttribute):
3515 (GenerateImplementation):
3516 (RequiresCustomSignature):
3518 2013-02-04 Kent Tamura <tkent@chromium.org>
3520 Fix crash by <select> type change on focus
3521 https://bugs.webkit.org/show_bug.cgi?id=108830
3523 Reviewed by Abhishek Arya.
3525 Test: fast/forms/select/select-change-type-on-focus.html
3527 * html/HTMLSelectElement.cpp:
3528 (WebCore::HTMLSelectElement::menuListDefaultEventHandler):
3529 focus() calls may change the renderer type.
3531 2013-02-04 Kentaro Hara <haraken@chromium.org>
3533 [V8] Pass an Isolate to opaqueRootForGC()
3534 https://bugs.webkit.org/show_bug.cgi?id=108886
3536 Reviewed by Adam Barth.
3538 No tests. No change in behavior.
3540 * bindings/scripts/CodeGeneratorV8.pm:
3541 (GenerateOpaqueRootForGC):
3543 * bindings/v8/V8GCController.cpp:
3544 (WebCore::V8GCController::opaqueRootForGC):
3545 * bindings/v8/WrapperTypeInfo.h:
3547 (WebCore::WrapperTypeInfo::opaqueRootForGC):
3548 * bindings/v8/custom/V8NodeListCustom.cpp:
3549 (WebCore::V8NodeList::opaqueRootForGC):
3551 2013-02-04 Wei James <james.wei@intel.com>
3553 Heap-buffer-overflow in WebCore::AudioBufferSourceNode::process
3554 https://bugs.webkit.org/show_bug.cgi?id=108515
3556 After calling setBuffer() with a buffer having a different number of
3557 channels, there can in rare cases be a slight delay before the output
3558 bus is updated to the new number of channels because of use of
3559 tryLocks() in the context's updating system.
3560 In this case, if the the buffer has just been changed and we're
3561 not quite ready yet then just output silence.
3563 Reviewed by Chris Rogers.
3565 * Modules/webaudio/AudioBufferSourceNode.cpp:
3566 (WebCore::AudioBufferSourceNode::process):
3567 (WebCore::AudioBufferSourceNode::renderFromBuffer):
3569 2013-02-04 James Simonsen <simonjam@chromium.org>
3571 [Chromium] Add a signal for when the body is inserted in the document
3572 https://bugs.webkit.org/show_bug.cgi?id=108725
3574 Reviewed by Adam Barth.
3576 This is an important signal for resource scheduling. We know we have enough to paint something,
3577 so we can start kicking off image preloads.
3579 Test: Chromium webkit_unit_tests
3581 * html/parser/HTMLConstructionSite.cpp:
3582 (WebCore::HTMLConstructionSite::insertHTMLBodyElement):
3583 * loader/FrameLoaderClient.h:
3584 (FrameLoaderClient):
3585 (WebCore::FrameLoaderClient::dispatchWillInsertBody):
3587 2013-02-04 Benjamin Poulain <bpoulain@apple.com>
3589 Kill suspendAnimation(), resumeAnimation() and numberOfActiveAnimations() from DRT/WTR; use Internals
3590 https://bugs.webkit.org/show_bug.cgi?id=108741
3592 Reviewed by Tony Chang.
3594 Move suspendAnimations and resumeAnimations to group all the animation related
3597 Add support for numberOfActiveAnimations, similarily to the feature previously defined
3600 * testing/Internals.cpp:
3601 (WebCore::Internals::numberOfActiveAnimations):
3603 (WebCore::Internals::suspendAnimations):
3604 (WebCore::Internals::resumeAnimations):
3605 * testing/Internals.h:
3607 * testing/Internals.idl:
3609 2013-02-04 Nayan Kumar K <nayankk@motorola.com>
3611 [WEBGL] Rename WEBKIT_WEBGL_compressed_texture_s3tc to WEBGL_compressed_texture_s3tc
3612 https://bugs.webkit.org/show_bug.cgi?id=108866
3614 Reviewed by Kenneth Russell.
3616 WEBGL_compressed_texture_s3tc is one of the community approved WebGL extension.
3617 Hence remove the vendor prefix from WEBKIT_WEBGL_compressed_texture_s3tc.
3618 Specification: http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
3620 No tests currently present to test WEBKIT_WEBGL_compressed_texture_s3tc.
3622 * bindings/js/JSWebGLRenderingContextCustom.cpp:
3624 * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
3625 (WebCore::toV8Object):
3626 * html/canvas/WebGLCompressedTextureS3TC.cpp:
3627 (WebCore::WebGLCompressedTextureS3TC::getName):
3628 * html/canvas/WebGLExtension.h:
3629 * html/canvas/WebGLRenderingContext.cpp:
3631 (WebCore::WebGLRenderingContext::getExtension):
3633 2013-02-04 Nayan Kumar K <nayankk@motorola.com>
3635 [WEBGL] Rename WEBKIT_WEBGL_lose_context to WEBGL_lose_context.
3636 https://bugs.webkit.org/show_bug.cgi?id=108694
3638 Reviewed by Kenneth Russell.
3640 WEBGL_lose_context is one of the community approved WebGL extension.
3641 Hence remove the vendor prefix from WEBKIT_WEBGL_lose_context extension.
3642 Spefication: http://www.khronos.org/registry/webgl/extensions/WEBGL_lose_context/
3644 Tests already exists, modified them to verify the change in extension name.
3646 * bindings/js/JSWebGLRenderingContextCustom.cpp:
3648 * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
3649 (WebCore::toV8Object):
3650 * html/canvas/WebGLExtension.h:
3651 * html/canvas/WebGLLoseContext.cpp:
3652 (WebCore::WebGLLoseContext::getName):
3653 * html/canvas/WebGLRenderingContext.cpp:
3655 (WebCore::WebGLRenderingContext::getExtension):
3656 (WebCore::WebGLRenderingContext::getSupportedExtensions):
3658 2013-02-04 Dean Jackson <dino@apple.com>
3660 Default element styles are not always collected for sharing detection
3661 https://bugs.webkit.org/show_bug.cgi?id=108404
3663 Reviewed by Antti Koivisto.
3665 The method ensureDefaultStyleSheetsForElement is run as we add elements
3666 to the document. This may update the defaultStyle of the document, but
3667 does not recollect any changes into the StyleResolver. This means that
3668 style sharing might be overly ambitious, thinking it can share a style
3669 for an element which was matched in the new rules. This showed up most
3670 often in the Shadow Root for media elements, which would add a set of
3671 style rules, but the shadow children would sometimes share styles even
3672 when they shouldn't.
3674 The fix is to detect if we need to collect after adding a
3675 style for an element. This might cause a little more work, but
3676 in my testing it doesn't happen very often.
3678 Unfortunately it is hard to get a reproducible test for this.
3680 * css/CSSDefaultStyleSheets.cpp:
3681 (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement): As we load in
3682 styles, keep track of whether or not we change the default style.
3683 * css/CSSDefaultStyleSheets.h:
3684 (CSSDefaultStyleSheets): New boolean parameter indicating if the style has changed.
3685 * css/StyleResolver.cpp:
3686 (WebCore::StyleResolver::styleForElement): Collect features if the element
3687 caused the default style to update.
3688 (WebCore::StyleResolver::collectFeatures): Protect for null in updates.
3690 2013-02-04 Jun Jiang <jun.a.jiang@intel.com>
3692 Fix the issue that some possible source formats are ignored for float textures in texture packing for CG port
3693 https://bugs.webkit.org/show_bug.cgi?id=108812
3695 Reviewed by Kenneth Russell.
3697 Already covered by latest WebGL conformance test.
3699 * platform/graphics/GraphicsContext3D.cpp:
3702 2013-02-04 Gyuyoung Kim <gyuyoung.kim@samsung.com>
3704 [EFL] Remove needless local variables in LocalizedStringsEfl.cpp
3705 https://bugs.webkit.org/show_bug.cgi?id=108869
3707 Reviewed by Kentaro Hara.
3709 fromUTF8() returns static String. So, we don't need to use needless local variables.
3711 * platform/efl/LocalizedStringsEfl.cpp:
3712 (WebCore::contextMenuItemTagCopy):
3713 (WebCore::contextMenuItemTagDelete):
3714 (WebCore::contextMenuItemTagSelectAll):
3715 (WebCore::contextMenuItemTagGoBack):
3716 (WebCore::contextMenuItemTagGoForward):
3717 (WebCore::contextMenuItemTagStop):
3718 (WebCore::contextMenuItemTagCut):
3719 (WebCore::contextMenuItemTagPaste):
3720 (WebCore::contextMenuItemTagBold):
3721 (WebCore::contextMenuItemTagItalic):
3722 (WebCore::contextMenuItemTagUnderline):
3724 2013-02-04 Jun Jiang <jun.a.jiang@intel.com>
3726 WebGL: Move the format conversion for 16-bit per channel formats into Core Graphics port only
3727 https://bugs.webkit.org/show_bug.cgi?id=108304
3729 Reviewed by Kenneth Russell.
3731 Since the 16-bit per channel formats are only used for Core Graphics port in WebGL and not a standard to represent any file format that is widely used
3732 for each platform, it is better to limit and hide this kinds of information and processing in CG specific code only.
3733 It can make the code more clear and reduce the binary size for both CG port and non-CG port.
3735 Already covered by current tests.
3737 * platform/graphics/GraphicsContext3D.cpp:
3739 * platform/graphics/GraphicsContext3D.h:
3740 (GraphicsContext3D):
3741 (WebCore::GraphicsContext3D::srcFormatComeFromDOMElementOrImageData):
3743 * platform/graphics/cg/GraphicsContext3DCG.cpp:
3745 (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
3747 2013-02-04 Dean Jackson <dino@apple.com>
3749 Allow TextTracks to be marked as closed captions
3750 https://bugs.webkit.org/show_bug.cgi?id=108856
3752 Reviewed by Darin Adler.
3754 While this isn't exposed directly in markup, some platform media frameworks can
3755 provide indication that a caption track is a closed caption. Expose such a flag
3756 on TextTrack and platforms can show a different UI if they want to.
3758 No tests - this isn't used elsewhere yet, nor exposed to the DOM.
3760 * html/track/TextTrack.cpp:
3761 (WebCore::TextTrack::TextTrack): Initialise new member.
3762 * html/track/TextTrack.h:
3763 (WebCore::TextTrack::isClosedCaptions): New member variable.
3764 (WebCore::TextTrack::setIsClosedCaptions):
3766 2013-02-04 Chris Hopman <cjhopman@chromium.org>
3768 Make moveCaretTowardsWindowPoint not snap to the beginning/end when moved above/below editable
3769 https://bugs.webkit.org/show_bug.cgi?id=107850
3771 Reviewed by Ojan Vafai.
3773 On Android, EditingBehavior::shouldMoveCaret[...] controls the
3774 behavior of insertion handles. This change adds a new Android specific
3775 editing behavior type.
3777 The new EditingBehavior is the same as EditingUnixBehavior except for
3778 EditingBehavior::shouldMoveCaret[...]. This new behavior fixes
3779 WebFrame::moveCaretTowardsWindowPoint to not span to the
3782 * editing/EditingBehavior.h:
3783 (WebCore::EditingBehavior::shouldMoveCaretToHorizontalBoundaryWhenPastTopOrBottom):
3784 (WebCore::EditingBehavior::shouldAllowSpellingSuggestionsWithoutSelection):
3785 (WebCore::EditingBehavior::shouldNavigateBackOnBackspace):
3786 * editing/EditingBehaviorTypes.h:
3787 * page/Settings.cpp:
3789 (WebCore::editingBehaviorTypeForPlatform):
3790 * testing/InternalSettings.cpp:
3791 (WebCore::InternalSettings::setEditingBehavior):
3793 2013-02-04 Kent Tamura <tkent@chromium.org>
3795 INPUT_MULTIPLE_FIELDS_UI: Focus order is not controllable by tabIndex attribute on <input>
3796 https://bugs.webkit.org/show_bug.cgi?id=108447
3798 Reviewed by Hajime Morita.
3800 We make <input> elements with the multiple-fields UI focusable.
3801 - However, we don't want to change the existing focus behavior for
3802 multiple-fields <input>. We'd like to focus on the last sub-field of
3803 an<input> with Shift + TAB focus navigation, and focus on the first
3804 sub-field of the <input> otherwise. So, we move focus immediately
3805 after the <input> gets focus.
3806 - We don't need the isFocusableByClickOnLabel hack any more. <input>
3807 elements with the multiple-fields UI are mouse-focusable.
3809 Test: fast/forms/time-multiple-fields/time-multiple-fields-tabindex.html
3812 (InputType): Add FocusDirection argument to handleFocusEvent, and remove
3813 unnecessary isFocusableByClickOnLabel and focus.
3814 * html/InputType.cpp:
3815 (WebCore::InputType::handleFocusEvent): Ditto.
3816 * html/PasswordInputType.cpp:
3817 (WebCore::PasswordInputType::handleFocusEvent): Follow the argument change.
3818 * html/PasswordInputType.h:
3819 (PasswordInputType): Ditto.
3821 * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
3822 (WebCore::BaseMultipleFieldsDateAndTimeInputType::handleFocusEvent):
3823 If this element gets focus by FocusDirectionBackward (it means the focus
3824 is moved from the first sub-field of the element,) move the focus
3825 backward once more. Otherwise, we focus on the first sub-filed of the
3827 (WebCore::BaseMultipleFieldsDateAndTimeInputType::isKeyboardFocusable):
3828 Make this keyboard-focusable. We have a wrong test to ensure read-only
3829 input does NOT get focus. We'll address it later.
3830 (WebCore::BaseMultipleFieldsDateAndTimeInputType::isMouseFocusable):
3831 Make this mouse-focusable.
3832 * html/BaseMultipleFieldsDateAndTimeInputType.h:
3833 (BaseMultipleFieldsDateAndTimeInputType):
3835 * html/HTMLInputElement.h:
3836 (HTMLInputElement): Remove defaultFocus, focus, and isFocusableByClickOnLabel.
3837 Add missing OVERRIDE to handleFocusEvent.
3838 * html/HTMLInputElement.cpp: Remove unnecessary functions.
3839 (WebCore::HTMLInputElement::handleFocusEvent):
3840 Pass FocusDirection value to InputTYpe::handleFocusEvent.
3842 * html/HTMLLabelElement.cpp:
3843 (WebCore::HTMLLabelElement::defaultEventHandler):
3844 Use isMouseFocusable().
3845 * html/HTMLElement.cpp: Remove unnecessary isFocusableByClickOnLabel.
3846 * html/HTMLElement.h: Ditto.
3848 2013-02-04 Seulgi Kim <seulgikim@company100.net>
3850 Coordinated Graphics: crash in TiledBackingStore::adjustForContentsRect
3851 https://bugs.webkit.org/show_bug.cgi?id=107639
3853 Reviewed by Kenneth Rohde Christiansen.
3855 In TiledBackingStore::adjustForContentsRect method, inflating is not
3856 needed when there is no intersections between the cover/keep rect and
3859 No new tests, no change in functionality.
3861 * platform/graphics/TiledBackingStore.cpp:
3862 (WebCore::TiledBackingStore::adjustForContentsRect):
3864 2013-02-04 Stephen White <senorblanco@chromium.org>
3866 [skia] Remove use of SkSingleInputImageFilter.
3867 https://bugs.webkit.org/show_bug.cgi?id=108867
3869 Reviewed by James Robinson.
3871 This class is but a hollow shell of its former self, and has
3872 been removed in Skia.
3874 Covered by existing tests in css3/filters.
3876 * platform/graphics/filters/skia/DropShadowImageFilter.cpp:
3877 (WebCore::DropShadowImageFilter::DropShadowImageFilter):
3878 (WebCore::DropShadowImageFilter::onFilterImage):
3879 * platform/graphics/filters/skia/DropShadowImageFilter.h:
3881 2013-01-31 Kentaro Hara <haraken@chromium.org>
3883 Implement WheelEvent::deltaMode
3884 https://bugs.webkit.org/show_bug.cgi?id=108455
3886 Reviewed by Adam Barth.
3888 Per the spec, WheelEvent::deltaMode should return
3889 DOM_DELTA_PIXEL or DOM_DELTA_LINE or DOM_DELTA_PAGE.
3891 Spec: http://www.w3.org/TR/DOM-Level-3-Events/#events-wheelevents
3892 https://dvcs.w3.org/hg/d4e/raw-file/tip/source_respec.htm#constructor-wheelevent
3894 Test: fast/event/wheel-event-constructor.html
3896 * dom/WheelEvent.cpp:
3897 (WebCore::WheelEventInit::WheelEventInit):
3898 (WebCore::WheelEvent::WheelEvent):
3899 (WebCore::WheelEvent::initWheelEvent):
3900 (WebCore::deltaMode):
3903 (WebCore::WheelEvent::create):
3904 (WebCore::WheelEvent::deltaMode):
3906 * dom/WheelEvent.idl:
3907 * page/EventHandler.cpp:
3908 (WebCore::wheelGranularityToScrollGranularity):
3910 2013-02-04 Gustavo Noronha Silva <gns@gnome.org>
3912 [Soup] Remove duplicate setting of first party for cookies
3913 https://bugs.webkit.org/show_bug.cgi?id=108814
3915 Reviewed by Martin Robinson.
3917 Covered by existing tests.
3919 * platform/network/soup/ResourceHandleSoup.cpp:
3920 (WebCore::createSoupMessageForHandleAndRequest): there is no need to set
3921 the first party for cookies here, since that is already done in
3922 ResourceRequest::updateSoupMessage, which is called a few lines before.
3924 2013-02-04 Gustavo Noronha Silva <gustavo.noronha@collabora.com>
3926 [GStreamer][Soup] Let GStreamer provide the buffer data is downloaded to, to avoid copying
3927 https://bugs.webkit.org/show_bug.cgi?id=105552
3929 Reviewed by Philippe Normand.
3931 Makes it possible for the GStreamer media backend to provide the buffer to which
3932 the Soup networking backend will use to download data to. This makes copying
3933 memory unnecessary when ResourceHandle hands data over to the media player's
3934 StreamingClient. Thanks to Dan Winship for help designing the interface.
3936 No behaviour change, covered by existing tests.
3938 * platform/graphics/gstreamer/GStreamerVersioning.cpp:
3939 (createGstBufferForData): New helper to create a GstBuffer when
3940 we have a data pointer and a length.
3941 (getGstBufferSize): Abstract obtaining the size of the buffer, so the code
3942 is cleaner while still working for both GST 0.10 and 1.0.
3943 (setGstBufferSize): Ditto, but for setting the size.
3944 (getGstBufferDataPointer): Ditto, but for grabbing the data pointer.
3945 (mapGstBuffer): Convenience method to take care of mapping the buffer so that
3946 we can provide the data pointer to ResourceHandle.
3947 (unmapGstBuffer): Convenience method which takes care of unmapping the buffer
3948 and properly freeing the GstMapInfo.
3949 * platform/graphics/gstreamer/GStreamerVersioning.h:
3950 * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
3951 (StreamingClient): New methods.
3952 (_WebKitWebSrcPrivate): We now store the GstBuffer we provided the data pointer from
3953 so we can later unmap it and push it to the pipeline.
3954 (webKitWebSrcDispose): Deal with the GstBuffer in case it exists when the source is
3956 (webKitWebSrcStop): Also clear the GstBuffer in this case.
3957 (StreamingClient::didReceiveData): Handle the hand-over of the buffer.
3958 (StreamingClient::getBuffer): Provide ResourceHandle with a new GstBuffer's data pointer.
3959 * platform/network/ResourceHandleClient.h:
3960 (ResourceHandleClient):
3961 (WebCore::ResourceHandleClient::ResourceHandleClient): Constructor to initialize the buffer
3962 member variable to 0.
3963 (WebCore::ResourceHandleClient::~ResourceHandleClient): Destructor to free the buffer if it
3965 (WebCore::ResourceHandleClient::getBuffer): Default implementation which returns a
3966 newly allocated char pointer.
3967 * platform/network/ResourceHandleInternal.h:
3968 (WebCore::ResourceHandleInternal::ResourceHandleInternal):
3969 (ResourceHandleInternal): Store actual buffer size, which is no longer a constant.
3970 * platform/network/soup/ResourceHandleSoup.cpp:
3971 (WebCore::cleanupSoupRequestOperation): Clear the buffer pointer, the life-cycle of the
3972 buffer is handled by the ResourceHandleClient.
3973 (WebCore::nextMultipartResponsePartCallback): Get a new buffer from the client before reading.
3974 (WebCore::sendRequestCallback): Ditto.
3975 (WebCore::readCallback): Ditto.
3977 2013-02-04 Mark Pilgrim <pilgrim@chromium.org>
3979 [Chromium] Move WorkerContextProxy to WebCore
3980 https://bugs.webkit.org/show_bug.cgi?id=108847
3982 Reviewed by Adam Barth.
3984 Part of a larger refactoring series; see tracking bug 106829.
3986 * WebCore.gyp/WebCore.gyp:
3988 * workers/chromium: Added.
3989 * workers/chromium/WorkerContextProxyChromium.cpp: Added.
3991 (WebCore::setWorkerContextProxyCreateFunction):
3992 (WebCore::WorkerContextProxy::create):
3993 * workers/chromium/WorkerContextProxyChromium.h: Added.
3996 2013-02-04 Dima Gorbik <dgorbik@apple.com>
3998 WebVTT <i>, <b> and <u> elements should have default styles
3999 https://bugs.webkit.org/show_bug.cgi?id=107214
4001 Reviewed by Darin Adler.
4003 Added default styles for basic webvtt object types.
4005 Test: media/track/track-css-matching-default.html
4007 * css/mediaControls.css:
4008 (video::-webkit-media-text-track-container b):
4009 (video::-webkit-media-text-track-container u):
4010 (video::-webkit-media-text-track-container i):
4012 2013-02-04 Abhishek Arya <inferno@chromium.org>
4014 Add ASSERT_WITH_SECURITY_IMPLICATION to detect out of bounds access
4015 https://bugs.webkit.org/show_bug.cgi?id=108668
4017 Reviewed by Eric Seidel.
4019 * bindings/v8/SerializedScriptValue.cpp:
4020 * css/CSSCalculationValue.cpp:
4021 (WebCore::CSSCalcExpressionNodeParser::parseCalc):
4022 * css/CSSImageSetValue.cpp:
4023 (WebCore::CSSImageSetValue::fillImageSet):
4024 (WebCore::CSSImageSetValue::customCssText):
4025 * css/CSSParserValues.h:
4026 (WebCore::CSSParserString::operator[]):
4027 * css/CSSValueList.h:
4028 (WebCore::CSSValueListInspector::item):
4029 * css/StyleSheetContents.cpp:
4030 (WebCore::StyleSheetContents::ruleAt):
4031 (WebCore::StyleSheetContents::wrapperInsertRule):
4032 (WebCore::StyleSheetContents::wrapperDeleteRule):
4034 (WebCore::Document::processArguments):
4036 (WebCore::Element::removeAttributeInternal):