[Github-comments] [geany/geany] Context menu update (#2550)

Ru Uba notifications at xxxxx
Sat Jul 18 01:24:56 UTC 2020


@SavSanta commented on this pull request.



> +
+
+static void on_copy_full_path_to_clipboard_activate(GtkMenuItem *menuitem, GeanyDocument *doc)
+{
+	g_return_if_fail(doc->is_valid);
+	
+	gtk_clipboard_set_text(gtk_clipboard_get(GDK_NONE), doc->real_path, -1);
+}
+
+
+static void on_copy_dir_path_to_clipboard_activate(GtkMenuItem *menuitem, GeanyDocument *doc)
+{
+	g_return_if_fail(doc->is_valid);
+
+	gchar *dirpath = g_path_get_basename(doc->real_path);
+	gtk_clipboard_set_text(gtk_clipboard_get(GDK_NONE), g_path_get_dirname(doc->real_path), -1);

Good catch Thanks

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/2550#discussion_r456732000
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20200717/e08c79e6/attachment.htm>


More information about the Github-comments mailing list