summaryrefslogtreecommitdiffstats
path: root/webkit/glue/cpp_bound_class_unittest.cc
diff options
context:
space:
mode:
authorananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-21 18:29:14 +0000
committerananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-21 18:29:14 +0000
commitf1a0eae704dcc8848847201d48922aa1984e522a (patch)
tree044105541a11d8db2468416711d2e9397e441038 /webkit/glue/cpp_bound_class_unittest.cc
parentdb5de6e6dc5b1692f2aa557ab1931246f43b775d (diff)
downloadchromium_src-f1a0eae704dcc8848847201d48922aa1984e522a.zip
chromium_src-f1a0eae704dcc8848847201d48922aa1984e522a.tar.gz
chromium_src-f1a0eae704dcc8848847201d48922aa1984e522a.tar.bz2
Relanding this fix. The earlier attempt broke test_shell_tests. The fix
has been added to this CB. Fix Silverlight windowless plugin painting issues. This fixes the following issues:- 1. http://code.google.com/p/chromium/issues/detail?id=4272 2. http://code.google.com/p/chromium/issues/detail?id=301 (Partially) The fixes are as below:- 1. Silverlight in the NPP_HandleEvent call for WM_PAINT, calls NPN_GetProperty for a bunch of properties like pageXOffset, pageYOffset, etc. It expects these properties to have integer types on return. We always return double. Firefox returns integer for these properties. Added a check in the conversion to NPVariant function in v8 to check for whether the value is an integer and return the intger type. 2. When the windowless plugin calls NPN_InvalidateRect we ask the plugin to paint in the same call, which the Silverlight plugin does not like. It relies on the fact that browsers would initiate invalidation asynchronously and eventually paint. This is a perfectly legal assumption. The Flash plugin does work if we synchronously ask it to paint. However other plugins could have similar issues. I verified with worldofwarcraft.com to see if the async paint has any sideeffects and there were none. 3.If the Silverlight plugin is not visible initially as on msdn.microsoft.com, it does not paint. This occurs because the plugin expects proper paints to come from the browser. It does not invalidate itself in UpdateGeometry as Flash. The plugin widget on msdn is not dynamic. It does call NPN_InvalidateRect initially when it is not visible. We don't send the call to the renderer as the plugin is not visible. To workaround this we now track the damaged rect even if the rect does not intersect the clipping rect of the plugin. In a geometry update if the plugin is visible, we send over the accumulated damaged rect to the renderer. The Silverlight plugin instance on msdn.microsoft.com does not work correctly even with these fixes. However it paints correctly. R=jam Bug=4272,301 Review URL: http://codereview.chromium.org/11569 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5829 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/cpp_bound_class_unittest.cc')
-rw-r--r--webkit/glue/cpp_bound_class_unittest.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/webkit/glue/cpp_bound_class_unittest.cc b/webkit/glue/cpp_bound_class_unittest.cc
index d57604a..73b118f2 100644
--- a/webkit/glue/cpp_bound_class_unittest.cc
+++ b/webkit/glue/cpp_bound_class_unittest.cc
@@ -194,7 +194,7 @@ TEST_F(CppBoundClassTest, InvokeMethods) {
"example.echoValue()", "null", // Too few arguments
"example.echoType(false)", "true",
- "example.echoType(19)", "3.14159",
+ "example.echoType(19)", "7",
"example.echoType(9.876)", "3.14159",
"example.echoType('test string')", "'Success!'",
"example.echoType()", "null", // Too few arguments