PATCH: Fix marked statistics in Catalog Manager

Marco Wegner <mail-/[email protected]>
Newsgroups gmane.comp.kde.devel.kbabel
Message-ID <[email protected]>
Hi,

I know we have discussed this almost a year ago :-)

When marking several files in a folder in Catalog Manager and afterwards 
selecting "Marked Statistics" then only the stats for one marked file or none 
at all (if the currently selected file is not marked) are displayed. To get 
the statistics for all the marked files in the current folder you have to 
select this folder and click "Marked Statistics" then.

The attached patch disables the menu entry as long as the current selection is 
not a folder or the folder does not contain marked files. IMHO this is more 
correct than it was before. What do you think?

Marco

_______________________________________________
kbabel mailing list
[email protected]
http://mail.kde.org/mailman/listinfo/kbabel
marked_statistics.diff (text/x-diff, 845 B)
Index: catalogmanager.cpp
===================================================================
RCS file: /home/kde/kdesdk/kbabel/catalogmanager/catalogmanager.cpp,v
retrieving revision 1.97
diff -u -3 -p -b -r1.97 catalogmanager.cpp
--- catalogmanager.cpp	12 Jun 2003 07:17:03 -0000	1.97
+++ catalogmanager.cpp	23 Jun 2003 08:04:18 -0000
@@ -328,7 +328,7 @@ void CatalogManager::setupActions()
                           _catalogManager, SLOT(mailMarkedFiles()), actionCollection(),	"mail_file_marked");
     action->setEnabled(false);
     
-    actionMap["statistics_marked"]        = NEEDS_MARK;
+    actionMap["statistics_marked"]        = NEEDS_DIR | NEEDS_MARK;
     actionMap["syntax"]                   = NEEDS_PO;
     actionMap["spellcheck"]               = NEEDS_PO;
     actionMap["spellcheck_marked"]        = NEEDS_PO | NEEDS_MARK;
signature.asc (application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQA+9raQX3rotM03gSgRAgU1AJ0d25LEyfGpE7K2iukkB9MjglchyQCguwk1
bKRTBuzRyJlNjq3o95Y3jRE=
=8Ror
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.