From 84cc52bd4fd197ec4aad845d9b09bcd5b74453d5 Mon Sep 17 00:00:00 2001 From: Tommi Komulainen Date: Tue, 25 Aug 2009 16:04:59 +0000 Subject: browser-plugin: add clipboard copy support Only supporting copy, evince doesn't support editing (at least the API is lacking cut and paste) Using property access workaround. Example: if (plugin.canCopy) { plugin.canCopy = 42; (workaround) copy selection to clipboard } --- (limited to 'browser-plugin/plugin.h') diff --git a/browser-plugin/plugin.h b/browser-plugin/plugin.h index 7ea940e..7da0aa3 100644 --- a/browser-plugin/plugin.h +++ b/browser-plugin/plugin.h @@ -39,6 +39,7 @@ class Plugin { void SetZoom (double); void FindNext (const char *text); void FindPrevious (const char *text); + void CopyClipboard (); void ShowLoadingError (); NPObject *GetScriptableNPObject (); @@ -51,6 +52,9 @@ class Plugin { static void SizingModeCallback (EvView *view, GParamSpec *pspec, gpointer data); + static void HasSelectionCallback (EvView *view, + GParamSpec *pspec, + gpointer data); static void ExternalLinkCallback (EvView *view, EvLinkAction *action, gpointer data); @@ -66,6 +70,7 @@ class Plugin { public: char *mTitle; + bool mHasSelection; }; void* NPN_MemDup (const void *aMem, uint32 aLen); -- cgit v0.9.1