summaryrefslogtreecommitdiff
path: root/src/evbp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/evbp.c')
-rw-r--r--src/evbp.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/evbp.c b/src/evbp.c
index d72dfac..ca7e834 100644
--- a/src/evbp.c
+++ b/src/evbp.c
@@ -38,7 +38,6 @@
#define EVBP_VERSION PACKAGE_VERSION
#define EVBP_NAME "Evince Plugin"
-#define EVBP_DESCRIPTION "Evince Browser Plugin " EVBP_VERSION
typedef struct evbp_priv {
NPP npp;
@@ -48,6 +47,7 @@ typedef struct evbp_priv {
} evbp_priv_t;
static char *evbp_mime_string = NULL;
+static char *evbp_description = NULL;
static const NPNetscapeFuncs *npn_funcs = NULL;
static gboolean ev_is_initialized = FALSE;
@@ -106,6 +106,12 @@ evbp_initialize(void)
textdomain(GETTEXT_PACKAGE);
#endif
+ /* Create the description string */
+ evbp_description = g_strdup_printf("Evince Broswer Plugin %s"
+ " (using Evince %u)",
+ EVBP_VERSION,
+ EV_MAJOR_VERSION);
+
/* Initialize gtk and evince icons */
gtk_init(NULL, NULL);
ev_stock_icons_init();
@@ -121,6 +127,7 @@ evbp_shutdown(void)
if (!ev_is_initialized)
return;
+ g_free(evbp_description);
ev_shutdown();
ev_stock_icons_shutdown();
@@ -296,7 +303,7 @@ evbp_get_value(NPP instance, NPPVariable variable, void *value)
*((char **)value) = EVBP_NAME;
break;
case NPPVpluginDescriptionString:
- *((char **)value) = EVBP_DESCRIPTION;
+ *((char **)value) = evbp_description;
break;
case NPPVpluginNeedsXEmbed:
/* Require XEmbed */