webpg-npapi 0.6.1
|
Constructor for the JSAPI object. Registers methods, properties, and events that should be accessible to Javascript.
Definition at line 81 of file webpgPluginAPI.cpp. References get_version(), get_webpg_status(), getKeyList(), getNamedKey(), getPrivateKeyList(), getPublicKeyList(), getTemporaryPath(), gpgAddUID(), gpgChangePassphrase(), gpgconf_detected(), gpgDecrypt(), gpgDeletePrivateKey(), gpgDeletePrivateSubKey(), gpgDeletePublicKey(), gpgDeleteUID(), gpgDeleteUIDSign(), gpgDisableKey(), gpgEnableKey(), gpgEncrypt(), gpgExportPublicKey(), gpgGenKey(), gpgGenSubKey(), gpgGetPreference(), gpgImportKey(), gpgRevokeKey(), gpgRevokeSignature(), gpgRevokeUID(), gpgSetHomeDir(), gpgSetKeyTrust(), gpgSetPreference(), gpgSetPrimaryUID(), gpgSetPubkeyExpire(), gpgSetSubkeyExpire(), gpgSignText(), gpgSignUID(), gpgSymmetricEncrypt(), init(), restoreGPGConfig(), and setTempGPGOption(). : m_plugin(plugin), m_host(host) { static bool allow_op = true; #ifdef _EXTENSIONIZE std::string location = m_host->getDOMWindow()->getLocation(); size_t firefox_ext = location.find("chrome://"); size_t chrome_ext = location.find("chrome-extension://"); if (chrome_ext != std::string::npos || firefox_ext != std::string::npos) allow_op = true; else allow_op = false; #endif if (allow_op == true) { registerMethod("getKeyList", make_method(this, &webpgPluginAPI::getKeyList)); registerMethod("getPublicKeyList", make_method(this, &webpgPluginAPI::getPublicKeyList)); registerMethod("getPrivateKeyList", make_method(this, &webpgPluginAPI::getPrivateKeyList)); registerMethod("getNamedKey", make_method(this, &webpgPluginAPI::getNamedKey)); registerMethod("gpgSetPreference", make_method(this, &webpgPluginAPI::gpgSetPreference)); registerMethod("gpgGetPreference", make_method(this, &webpgPluginAPI::gpgGetPreference)); registerMethod("gpgSetHomeDir", make_method(this, &webpgPluginAPI::gpgSetHomeDir)); registerMethod("gpgGetHomeDir", make_method(this, &webpgPluginAPI::gpgGetHomeDir)); registerMethod("gpgEncrypt", make_method(this, &webpgPluginAPI::gpgEncrypt)); registerMethod("gpgSymmetricEncrypt", make_method(this, &webpgPluginAPI::gpgSymmetricEncrypt)); registerMethod("gpgDecrypt", make_method(this, &webpgPluginAPI::gpgDecrypt)); registerMethod("gpgVerify", make_method(this, &webpgPluginAPI::gpgVerify)); registerMethod("gpgSignText", make_method(this, &webpgPluginAPI::gpgSignText)); registerMethod("gpgSignUID", make_method(this, &webpgPluginAPI::gpgSignUID)); registerMethod("gpgEnableKey", make_method(this, &webpgPluginAPI::gpgEnableKey)); registerMethod("gpgDisableKey", make_method(this, &webpgPluginAPI::gpgDisableKey)); registerMethod("gpgDeleteUIDSign", make_method(this, &webpgPluginAPI::gpgDeleteUIDSign)); registerMethod("gpgGenKey", make_method(this, &webpgPluginAPI::gpgGenKey)); registerMethod("gpgGenSubKey", make_method(this, &webpgPluginAPI::gpgGenSubKey)); registerMethod("gpgImportKey", make_method(this, &webpgPluginAPI::gpgImportKey)); registerMethod("gpgDeletePublicKey", make_method(this, &webpgPluginAPI::gpgDeletePublicKey)); registerMethod("gpgDeletePrivateKey", make_method(this, &webpgPluginAPI::gpgDeletePrivateKey)); registerMethod("gpgDeletePrivateSubKey", make_method(this, &webpgPluginAPI::gpgDeletePrivateSubKey)); registerMethod("gpgSetKeyTrust", make_method(this, &webpgPluginAPI::gpgSetKeyTrust)); registerMethod("gpgAddUID", make_method(this, &webpgPluginAPI::gpgAddUID)); registerMethod("gpgDeleteUID", make_method(this, &webpgPluginAPI::gpgDeleteUID)); registerMethod("gpgSetPrimaryUID", make_method(this, &webpgPluginAPI::gpgSetPrimaryUID)); registerMethod("gpgSetSubkeyExpire", make_method(this, &webpgPluginAPI::gpgSetSubkeyExpire)); registerMethod("gpgSetPubkeyExpire", make_method(this, &webpgPluginAPI::gpgSetPubkeyExpire)); registerMethod("gpgExportPublicKey", make_method(this, &webpgPluginAPI::gpgExportPublicKey)); registerMethod("gpgRevokeKey", make_method(this, &webpgPluginAPI::gpgRevokeKey)); registerMethod("gpgRevokeUID", make_method(this, &webpgPluginAPI::gpgRevokeUID)); registerMethod("gpgRevokeSignature", make_method(this, &webpgPluginAPI::gpgRevokeSignature)); registerMethod("gpgChangePassphrase", make_method(this, &webpgPluginAPI::gpgChangePassphrase)); registerMethod("setTempGPGOption", make_method(this, &webpgPluginAPI::setTempGPGOption)); registerMethod("restoreGPGConfig", make_method(this, &webpgPluginAPI::restoreGPGConfig)); registerMethod("getTemporaryPath", make_method(this, &webpgPluginAPI::getTemporaryPath)); registerEvent("onkeygenprogress"); registerEvent("onkeygencomplete"); } // Read-only property registerProperty("version", make_property(this, &webpgPluginAPI::get_version)); registerProperty("webpg_status", make_property(this, &webpgPluginAPI::get_webpg_status)); registerProperty("gpgconf_detected", make_property(this, &webpgPluginAPI::gpgconf_detected)); webpgPluginAPI::init(); }
Here is the call graph for this function:
|