| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 /* | 5 /* |
| 6 * Copyright (C) 2010 Apple Inc. All rights reserved. | 6 * Copyright (C) 2010 Apple Inc. All rights reserved. |
| 7 * | 7 * |
| 8 * Redistribution and use in source and binary forms, with or without | 8 * Redistribution and use in source and binary forms, with or without |
| 9 * modification, are permitted provided that the following conditions | 9 * modification, are permitted provided that the following conditions |
| 10 * are met: | 10 * are met: |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 // NPERR_GENERIC_ERROR. | 128 // NPERR_GENERIC_ERROR. |
| 129 return NPERR_GENERIC_ERROR; | 129 return NPERR_GENERIC_ERROR; |
| 130 } | 130 } |
| 131 | 131 |
| 132 NPError PluginTest::NPP_SetValue(NPNVariable, void* value) { | 132 NPError PluginTest::NPP_SetValue(NPNVariable, void* value) { |
| 133 return NPERR_GENERIC_ERROR; | 133 return NPERR_GENERIC_ERROR; |
| 134 } | 134 } |
| 135 | 135 |
| 136 // NPN functions. | 136 // NPN functions. |
| 137 | 137 |
| 138 NPError PluginTest::NPN_GetURL(const char* url, const char* target) { | |
| 139 return browser->geturl(m_npp, url, target); | |
| 140 } | |
| 141 | |
| 142 NPError PluginTest::NPN_GetURLNotify(const char* url, | |
| 143 const char* target, | |
| 144 void* notifyData) { | |
| 145 return browser->geturlnotify(m_npp, url, target, notifyData); | |
| 146 } | |
| 147 | |
| 148 NPError PluginTest::NPN_GetValue(NPNVariable variable, void* value) { | 138 NPError PluginTest::NPN_GetValue(NPNVariable variable, void* value) { |
| 149 return browser->getvalue(m_npp, variable, value); | 139 return browser->getvalue(m_npp, variable, value); |
| 150 } | 140 } |
| 151 | 141 |
| 152 void PluginTest::NPN_InvalidateRect(NPRect* invalidRect) { | 142 void PluginTest::NPN_InvalidateRect(NPRect* invalidRect) { |
| 153 browser->invalidaterect(m_npp, invalidRect); | 143 browser->invalidaterect(m_npp, invalidRect); |
| 154 } | 144 } |
| 155 | 145 |
| 156 bool PluginTest::NPN_Invoke(NPObject* npobj, | 146 bool PluginTest::NPN_Invoke(NPObject* npobj, |
| 157 NPIdentifier methodName, | 147 NPIdentifier methodName, |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 | 256 |
| 267 createTestFunctions()[identifier] = createTestFunction; | 257 createTestFunctions()[identifier] = createTestFunction; |
| 268 } | 258 } |
| 269 | 259 |
| 270 std::map<std::string, PluginTest::CreateTestFunction>& | 260 std::map<std::string, PluginTest::CreateTestFunction>& |
| 271 PluginTest::createTestFunctions() { | 261 PluginTest::createTestFunctions() { |
| 272 static std::map<std::string, CreateTestFunction> testFunctions; | 262 static std::map<std::string, CreateTestFunction> testFunctions; |
| 273 | 263 |
| 274 return testFunctions; | 264 return testFunctions; |
| 275 } | 265 } |
| OLD | NEW |