[CMAKE] Add TestNetscapePlugIn/Tests/NPRuntimeCallsWithNullNPP.cpp to CMakeLists.txt
https://bugs.webkit.org/show_bug.cgi?id=100681

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29
Reviewed by Anders Carlsson.

Add TestNetscapePlugIn/Tests/NPRuntimeCallsWithNullNPP.cpp to CMake since
it is needed by plugins/npruntime/npruntime-calls-with-null-npp.html
layout test.

* DumpRenderTree/TestNetscapePlugIn/CMakeLists.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132831 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSSOM] Extraneous whitespace in CSSImportRule.cssText
https://bugs.webkit.org/show_bug.cgi?id=100657

Patch by Glenn Adams <glenn@skynav.com> on 2012-10-29
Reviewed by Simon Fraser.

Source/WebCore:

Remove extraneous whitespace when serializing CSSImportRule.cssText when
media list is empty.

Test: cssom/cssimportrule-media.html

* css/CSSImportRule.cpp:
(WebCore::CSSImportRule::cssText):
Don't append extra whitespace if mediaText is empty.

LayoutTests:

Test (from CSS WG) that checks serializion of CSSImportRule.cssText.

* http/tests/css/shared-stylesheet-mutation-expected.txt:
* http/tests/css/shared-stylesheet-mutation-preconstruct-expected.txt:
Fix expected output to match removal of extraneous space.

* cssom/cssimportrule-media-expected.txt: Added.
* cssom/cssimportrule-media.html: Added.
* cssom/resources/import.css: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132834 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] flickering observed when copying 2D canvas to webGL texture
https://bugs.webkit.org/show_bug.cgi?id=100691

Reviewed by Stephen White.

Source/WebCore:

Added a flush to the webgl context after texture upload from an image
buffer to ensure proper graphics context synchronization with respect
to subsequent changes to the source image.

Tests: fast/canvas/webgl/canvas-2d-webgl-texture.html

* platform/graphics/skia/ImageBufferSkia.cpp:
(WebCore::ImageBuffer::copyToPlatformTexture):

LayoutTests:

Modified test by adding a canvas draw imediately after webgl texture
upload in order to exercise graphics context synchronization between
the webGL and 2D canvas graphics contexts.

* fast/canvas/webgl/canvas-2d-webgl-texture.html:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132839 268f45cc-cd09-0410-ab3c-d52691b4dbfc
webkitpy: change non-verbose log format for webkit-patch
https://bugs.webkit.org/show_bug.cgi?id=100561

Reviewed by Ojan Vafai.

Logging the module name and the log level is annoying and nearly useless.
For starters, this change removes that unless you are doing verbose/
debug logging. In the future we should split out the concepts of
verbose and debug logging (like we did in test-webkitpy and
run-webkit-tests) so that you could get this in debug logging.

* Scripts/webkitpy/common/system/logutils.py:
(_default_handlers):
(configure_logging):
* Scripts/webkitpy/common/system/logutils_unittest.py:
(ConfigureLoggingTest.test_info_message):
(ConfigureLoggingTest):
(ConfigureLoggingTest.test_debug_message):
(ConfigureLoggingTest.test_two_messages):
(ConfigureLoggingVerboseTest):
(ConfigureLoggingVerboseTest._logging_level):
(ConfigureLoggingVerboseTest.test_info_message):
(ConfigureLoggingVerboseTest.test_debug_message):
(ConfigureLoggingCustomLevelTest.test_logged_message):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132840 268f45cc-cd09-0410-ab3c-d52691b4dbfc
buildHTTPHeaders() should use a StringBuilder.appendLiteral() for separator
https://bugs.webkit.org/show_bug.cgi?id=100689

Reviewed by Darin Adler.

Changed from using a String temporary for the separator to using StringBuilder.appendLiteral(": ").

* WebProcess/Plugins/PluginView.cpp:
(WebKit::buildHTTPHeaders):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132841 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Support captions when PLUGIN_PROXY_FOR_VIDEO
https://bugs.webkit.org/show_bug.cgi?id=100690

Reviewed by Simon Fraser.

When built with PLUGIN_PROXY_FOR_VIDEO, WebCore uses a plug-in for the media element's
platform media engine. Update this code path so the shadow DOM elements used to display
text tracks are created and configured correctly.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::configureMediaControls): Create media controls if necessary.

* rendering/RenderEmbeddedObject.cpp:
(WebCore::RenderEmbeddedObject::layout): Set the position and size of the shadow DOM when the
    position of the embedded element changes.
* rendering/RenderEmbeddedObject.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132842 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed gardening. LayoutTests/mathml/msubsup-fuzz.html passes locally but not on
cr-linux-ews. I need to see a stack trace to debug it. See webkit.org/b/100463.

* mathml/msubsup-fuzz-expected.txt: Added.
* mathml/msubsup-fuzz.html: Added.
* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132843 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[skia] Handle mask box image.
https://bugs.webkit.org/show_bug.cgi?id=100570

Reviewed by James Robinson.

Source/WebCore:

When drawing an image with source rectangle it should intersect with image rectangle.
This should be the case for drawing single image and tiling an image.

Test: fast/images/mask-box-image-crash.html

* platform/graphics/skia/ImageSkia.cpp:
(WebCore::Image::drawPattern):
(WebCore::BitmapImage::draw):
(WebCore::BitmapImageSingleFrameSkia::draw):

LayoutTests:

Added a test for -webkit-mask-box-image. Test should complete without crashes.
Output image should be blank.

* fast/images/mask-box-image-crash-expected.png: Added.
* fast/images/mask-box-image-crash-expected.txt: Added.
* fast/images/mask-box-image-crash.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132844 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove ensureAuxiliaryContext
https://bugs.webkit.org/show_bug.cgi?id=99975

Patch by Dan Carney <dcarney@google.com> on 2012-10-29
Reviewed by Adam Barth.

Source/WebCore:

Removed auxilliaryContext as use if it is problematic in IDB.

No new tests. No change in functionality.

* Modules/indexeddb/IDBCursor.cpp:
(WebCore::IDBCursor::update):
(WebCore::IDBCursor::setValueReady):
* Modules/indexeddb/IDBCursor.h:
(IDBCursor):
* Modules/indexeddb/IDBObjectStore.cpp:
(WebCore::generateIndexKeysForValue):
(WebCore::IDBObjectStore::put):
(WebCore):
* Modules/indexeddb/IDBRequest.cpp:
(WebCore::IDBRequest::onSuccess):
(WebCore::IDBRequest::dispatchEvent):
* bindings/v8/IDBBindingUtilities.cpp:
(WebCore::createIDBKeyFromScriptValueAndKeyPath):
(WebCore::deserializeIDBValue):
(WebCore::injectIDBKeyIntoScriptValue):
* bindings/v8/IDBBindingUtilities.h:
(WebCore):
* bindings/v8/V8Binding.cpp:
(WebCore::toV8Context):
(WebCore):
* bindings/v8/V8Binding.h:
(WebCore):
* bindings/v8/V8PerIsolateData.cpp:
(WebCore):
* bindings/v8/V8PerIsolateData.h:

Source/WebKit/chromium:

Updated tests to use correct v8 context.

* tests/IDBBindingUtilitiesTest.cpp:
(WebKit::checkKeyFromValueAndKeyPathInternal):
(WebKit::checkKeyPathNullValue):
(WebKit::injectKey):
(WebKit::checkInjection):
(WebKit::checkInjectionFails):
(WebKit::checkKeyPathStringValue):
(WebKit::checkKeyPathNumberValue):
(WebKit::scriptExecutionContext):
(WebKit):
(WebKit::TEST):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132845 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed rebaseline of webaudio/audiobuffersource-loop-points

* platform/chromium-win-xp/webaudio/audiobuffersource-loop-points-expected.wav: Added.
* platform/chromium-win/webaudio/audiobuffersource-loop-points-expected.wav: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132846 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Let SVGElements have pending resources.
https://bugs.webkit.org/show_bug.cgi?id=99694

Reviewed by Eric Seidel.

Our SVG pending resource tracking is used for handling dynamic id changes. For example,
if an SVG element references an id that is not yet in the document (or has been removed),
the SVG element will be 'pending' an id. When styled elements are inserted into
the document, buildPendingResourcesIfNeeded() is called to force any pending elements
to resolve their dependencies. Only SVGStyledElement targets can be referenced using
this infrastructure, and that is not changed with this patch.

Previously, only SVGStyledElements could have pending resources. Some examples of where
this is violated are SVGAnimateElement and SVGMPathElement which are not a styled elements
but which can have pending references (they can reference styled elements and
paths, respectively). This patch changes the pending resource handling to allow
any SVGElement to have pending resources.

This patch is only a refactoring of code in preparation for WK99694 and does not
affect existing functionality or tests.

* svg/SVGDocumentExtensions.cpp:
(WebCore::SVGDocumentExtensions::addPendingResource):
(WebCore::SVGDocumentExtensions::isElementPendingResources):
(WebCore::SVGDocumentExtensions::isElementPendingResource):
(WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
(WebCore::SVGDocumentExtensions::removeElementFromPendingResourcesForRemoval):
* svg/SVGDocumentExtensions.h:
(WebCore):
(SVGDocumentExtensions):
* svg/SVGElement.cpp:
(WebCore::SVGElement::~SVGElement):
(WebCore::SVGElement::removedFrom):
(WebCore::SVGElement::hasPendingResources):
(WebCore):
(WebCore::SVGElement::setHasPendingResources):
(WebCore::SVGElement::clearHasPendingResourcesIfPossible):
* svg/SVGElement.h:
(SVGElement):
(WebCore::SVGElement::buildPendingResource):
* svg/SVGStyledElement.cpp:
(WebCore):
(WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
(WebCore::SVGStyledElement::removedFrom):
* svg/SVGStyledElement.h:
(SVGStyledElement):
(WebCore::SVGStyledElement::selfHasRelativeLengths):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132847 268f45cc-cd09-0410-ab3c-d52691b4dbfc
IndexedDB: Crash on checking version of corrupt backing store
https://bugs.webkit.org/show_bug.cgi?id=100692

Reviewed by Tony Chang.

If the backing store fails to open (due to corruption, non-writeable disk, etc)
the subsequent schema version check dereferences a null pointer. Fix to only
do the schema check if the database opened.

Chromium tests will be included with crrev.com/11196029

* Modules/indexeddb/IDBLevelDBBackingStore.cpp:
(WebCore::IDBLevelDBBackingStore::open):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132848 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Block SVG external references pending a security review
https://bugs.webkit.org/show_bug.cgi?id=100635

Reviewed by Eric Seidel.

Source/WebCore:

We need to do a security review of loading external SVG references
before we're sure that it is safe.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::createFilterOperations):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::canRequest):

Source/WTF:

We need to do a security review of loading external SVG references
before we're sure that it is safe.

* wtf/Platform.h:

LayoutTests:

Skip tests that depend on external SVG references.

* platform/chromium/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132849 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed. Feature introduced in r132708 is chromium only. Skipping related tests.

* platform/win/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132850 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Simplify AuthenticationChallengeManager::instance
https://bugs.webkit.org/show_bug.cgi?id=100614

Reviewed by Yong Li.
Internally reviewed by Lyon Chen.

Source/WebCore:

Use a standard Singleton pattern here, this makes sure we create lazily.

* platform/blackberry/AuthenticationChallengeManager.cpp:
(WebCore):
* platform/blackberry/AuthenticationChallengeManager.h:
(AuthenticationChallengeManager):

Source/WebKit/blackberry:

No need to call AuthenticationChallengeManager::init anymore.

* Api/BlackBerryGlobal.cpp:
(BlackBerry::WebKit::globalInitialize):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132851 268f45cc-cd09-0410-ab3c-d52691b4dbfc
<rdar://problem/12592716> REGRESSION (r132545): With full-page accelerated drawing, a
reproducible hang occurs at <http://www.cbsnews.com/stories/2010/01/24/ftn/main6136386.shtml>.

Reviewed by Anders Carlsson.

Work around <rdar://problem/12584492> by limiting the scope of the fix for <http://webkit.org/b/100413>.

* platform/graphics/cg/GraphicsContextCG.cpp:
(WebCore::GraphicsContext::clipOut): Reverted to using CGContextGetClipBoundingBox() rather
than CGRectInfinite when the context is accelerated and has a transform that is not just
a translation or a scale.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132852 268f45cc-cd09-0410-ab3c-d52691b4dbfc