| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "build/build_config.h" | 5 #include "build/build_config.h" |
| 6 | 6 |
| 7 #include "webkit/glue/plugins/plugin_instance.h" | 7 #include "webkit/glue/plugins/plugin_instance.h" |
| 8 | 8 |
| 9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 void* notify_data; | 171 void* notify_data; |
| 172 GetNotifyData(notify_id, ¬ify, ¬ify_data); | 172 GetNotifyData(notify_id, ¬ify, ¬ify_data); |
| 173 if (!notify) { | 173 if (!notify) { |
| 174 NOTREACHED(); | 174 NOTREACHED(); |
| 175 return; | 175 return; |
| 176 } | 176 } |
| 177 | 177 |
| 178 NPP_URLNotify(url.spec().c_str(), reason, notify_data); | 178 NPP_URLNotify(url.spec().c_str(), reason, notify_data); |
| 179 } | 179 } |
| 180 | 180 |
| 181 unsigned PluginInstance::GetBackingTextureId() { |
| 182 // By default the plugin instance is not backed by an OpenGL texture. |
| 183 return 0; |
| 184 } |
| 185 |
| 181 // NPAPI methods | 186 // NPAPI methods |
| 182 NPError PluginInstance::NPP_New(unsigned short mode, | 187 NPError PluginInstance::NPP_New(unsigned short mode, |
| 183 short argc, | 188 short argc, |
| 184 char *argn[], | 189 char *argn[], |
| 185 char *argv[]) { | 190 char *argv[]) { |
| 186 DCHECK(npp_functions_ != 0); | 191 DCHECK(npp_functions_ != 0); |
| 187 DCHECK(npp_functions_->newp != 0); | 192 DCHECK(npp_functions_->newp != 0); |
| 188 DCHECK(argc >= 0); | 193 DCHECK(argc >= 0); |
| 189 | 194 |
| 190 if (npp_functions_->newp != 0) { | 195 if (npp_functions_->newp != 0) { |
| (...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 623 *notify = true; | 628 *notify = true; |
| 624 *notify_data = iter->second; | 629 *notify_data = iter->second; |
| 625 pending_requests_.erase(iter); | 630 pending_requests_.erase(iter); |
| 626 } else { | 631 } else { |
| 627 *notify = false; | 632 *notify = false; |
| 628 *notify_data = NULL; | 633 *notify_data = NULL; |
| 629 } | 634 } |
| 630 } | 635 } |
| 631 | 636 |
| 632 } // namespace NPAPI | 637 } // namespace NPAPI |
| OLD | NEW |