From 8037461bbb0085344121d9f630fd7bb316b4201a Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Tue, 21 May 2013 06:03:17 +0200 Subject: [PATCH] Implemented one more callback in the popup menu --- src/ghtml-webkit.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/ghtml-webkit.c b/src/ghtml-webkit.c index 256838e..2ce24d0 100644 --- a/src/ghtml-webkit.c +++ b/src/ghtml-webkit.c @@ -1098,7 +1098,16 @@ static void _context_menu_separator(GtkWidget * menu, gboolean * separator) /* on_copy_link_location */ static void _on_copy_link_location(gpointer data) { - /* FIXME implement */ + GHtml * ghtml = data; + GdkAtom * atom; + GtkClipboard * clipboard; + + /* we can ignore errors */ + atom = gdk_atom_intern ("CLIPBOARD", FALSE); + clipboard = gtk_clipboard_get(atom); + gtk_clipboard_set_text(clipboard, ghtml->popup_uri, -1); + free(ghtml->popup_uri); + ghtml->popup_uri = NULL; } #endif