[git] GPA - branch, master, updated. gpa-0.9.4-44-g8bbf24b

by Daniel Kahn Gillmor cvs at cvs.gnupg.org
Tue Sep 2 08:56:51 CEST 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Assistant".

The branch, master has been updated
       via  8bbf24ba918bae0d593ce5431c234789cfad8a7b (commit)
      from  03cb3b876c775675b722e7be05d35d1ef260cb1e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 8bbf24ba918bae0d593ce5431c234789cfad8a7b
Author: Daniel Kahn Gillmor <dkg at fifthhorseman.net>
Date:   Mon Sep 1 21:29:36 2014 -0400

    Add a File/Close option to the card manager.
    
    * src/cardman.c (file_close): New.
    (cardman_action_new): Add menu item.
    --
    
    All the other windows have a File|Close option, but the card manager
    only has File|Quit.  As a result, a user who tries to close the card
    manager from the menubar will most likely shut down all of GPA, which
    may not be their intent.

diff --git a/src/cardman.c b/src/cardman.c
index c752442..844a44a 100644
--- a/src/cardman.c
+++ b/src/cardman.c
@@ -624,6 +624,15 @@ watcher_cb (void *opaque, const char *filename, const char *reason)
 }
 
 
+/* Handle menu item "File/Close".  */
+static void
+file_close (GtkAction *action, gpointer param)
+{
+  GpaCardManager *cardman = param;
+  gtk_widget_destroy (GTK_WIDGET (cardman));
+}
+
+
 /* Construct the card manager menu and toolbar widgets and return
    them. */
 static void
@@ -638,6 +647,8 @@ cardman_action_new (GpaCardManager *cardman, GtkWidget **menubar,
       { "Card", NULL, N_("_Card"), NULL },
 
       /* File menu.  */
+      { "FileClose", GTK_STOCK_CLOSE, NULL, NULL,
+	N_("Close the window"), G_CALLBACK (file_close) },
       { "FileQuit", GTK_STOCK_QUIT, NULL, NULL,
 	N_("Quit the program"), G_CALLBACK (gtk_main_quit) },
 
@@ -652,6 +663,7 @@ cardman_action_new (GpaCardManager *cardman, GtkWidget **menubar,
     "<ui>"
     "  <menubar name='MainMenu'>"
     "    <menu action='File'>"
+    "      <menuitem action='FileClose'/>"
     "      <menuitem action='FileQuit'/>"
     "    </menu>"
     "    <menu action='Edit'>"

-----------------------------------------------------------------------

Summary of changes:
 src/cardman.c |   12 ++++++++++++
 1 file changed, 12 insertions(+)


hooks/post-receive
-- 
The GNU Privacy Assistant
http://git.gnupg.org




More information about the Gnupg-commits mailing list