Index: src/trusted/plugin/npapi/plugin_npapi.cc |
=================================================================== |
--- src/trusted/plugin/npapi/plugin_npapi.cc (revision 2995) |
+++ src/trusted/plugin/npapi/plugin_npapi.cc (working copy) |
@@ -170,6 +170,21 @@ |
NPError ret = NPERR_GENERIC_ERROR; |
PLUGIN_PRINTF(("PluginNpapi::SetWindow(%p, %p)\n", static_cast<void* >(this), |
static_cast<void*>(window))); |
+ |
+// NOTE(gregoryd): Chrome does not allow us to call NPN_GetUrl during |
+// initialization, but does call SetWindows afterwards, so we use this call |
+// to trigger the download if the src property hasn't been specified. |
Mark Seaborn
2010/08/16 15:13:59
Can you link to the Chromium bug here?
gregoryd
2010/08/16 18:41:09
There is no Chromium bug. I spoke to Brett Wilson
|
+#if !defined(NACL_STANDALONE) |
+ // If the <embed src='...'> attr was defined, the browser would have |
+ // implicitly called GET on it, which calls Load() and set_logical_url(). |
+ // In the absence of this attr, we use the "nexes" attribute if present. |
+ if (logical_url() == NULL) { |
+ const char* nexes_attr = LookupArgument("nexes"); |
+ if (nexes_attr != NULL) { |
+ SetNexesPropertyImpl(nexes_attr); |
+ } |
+ } |
+#endif |
if (NULL == module_) { |
if (video() && video()->SetWindow(window)) { |
ret = NPERR_NO_ERROR; |