OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "config.h" | 5 #include "config.h" |
6 #include "webkit/glue/plugins/webplugin_delegate_impl.h" | 6 #include "webkit/glue/plugins/webplugin_delegate_impl.h" |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 const int kFlashWMUSERMessageThrottleDelayMs = 5; | 43 const int kFlashWMUSERMessageThrottleDelayMs = 5; |
44 | 44 |
45 // The current instance of the plugin which entered the modal loop. | 45 // The current instance of the plugin which entered the modal loop. |
46 WebPluginDelegateImpl* g_current_plugin_instance = NULL; | 46 WebPluginDelegateImpl* g_current_plugin_instance = NULL; |
47 | 47 |
48 // base::LazyInstance<std::list<MSG> > g_throttle_queue(base::LINKER_INITIALIZED
); | 48 // base::LazyInstance<std::list<MSG> > g_throttle_queue(base::LINKER_INITIALIZED
); |
49 | 49 |
50 | 50 |
51 } // namespace | 51 } // namespace |
52 | 52 |
53 WebPluginDelegateImpl* WebPluginDelegateImpl::Create( | 53 WebPluginDelegate* WebPluginDelegate::Create( |
54 const FilePath& filename, | 54 const FilePath& filename, |
55 const std::string& mime_type, | 55 const std::string& mime_type, |
56 gfx::NativeView containing_view) { | 56 gfx::NativeView containing_view) { |
57 scoped_refptr<NPAPI::PluginLib> plugin = | 57 scoped_refptr<NPAPI::PluginLib> plugin = |
58 NPAPI::PluginLib::CreatePluginLib(filename); | 58 NPAPI::PluginLib::CreatePluginLib(filename); |
59 if (plugin.get() == NULL) | 59 if (plugin.get() == NULL) |
60 return NULL; | 60 return NULL; |
61 | 61 |
62 NPError err = plugin->NP_Initialize(); | 62 NPError err = plugin->NP_Initialize(); |
63 if (err != NPERR_NO_ERROR) | 63 if (err != NPERR_NO_ERROR) |
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
448 } | 448 } |
449 | 449 |
450 void WebPluginDelegateImpl::URLRequestRouted(const std::string&url, | 450 void WebPluginDelegateImpl::URLRequestRouted(const std::string&url, |
451 bool notify_needed, | 451 bool notify_needed, |
452 void* notify_data) { | 452 void* notify_data) { |
453 if (notify_needed) { | 453 if (notify_needed) { |
454 instance()->SetURLLoadData(GURL(url.c_str()), notify_data); | 454 instance()->SetURLLoadData(GURL(url.c_str()), notify_data); |
455 } | 455 } |
456 } | 456 } |
457 | 457 |
OLD | NEW |