aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBoby Wang <boby.wang@sun.com>2006-03-20 14:27:55 +0800
committerLi Yuan <liyuan@src.gnome.org>2006-03-20 14:27:55 +0800
commit43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b (patch)
treebf1480e75d287f432754816fa42e75b471c1ac68
parent4a19f6a83850664c2c64ff0115861f9c31680f06 (diff)
downloadgsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar.gz
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar.bz2
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar.lz
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar.xz
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.tar.zst
gsoc2013-evolution-43f8ec830ed5b415baeb4d70d95c69e9c1f8e20b.zip
Fix for #319308
2006-03-20 Boby Wang <boby.wang@sun.com> Fix for #319308 * addressbook/ea-minicard-view.c: (ea_minicard_view_get_name): add the folder name to the name of current minicard view svn path=/trunk/; revision=31723
-rw-r--r--a11y/ChangeLog6
-rw-r--r--a11y/addressbook/ea-minicard-view.c21
2 files changed, 22 insertions, 5 deletions
diff --git a/a11y/ChangeLog b/a11y/ChangeLog
index 4060cd0cee..5311672006 100644
--- a/a11y/ChangeLog
+++ b/a11y/ChangeLog
@@ -1,3 +1,9 @@
+2006-03-20 Boby Wang <boby.wang@sun.com>
+ Fix for #319308
+
+ * addressbook/ea-minicard-view.c: (ea_minicard_view_get_name):
+ add the folder name to the name of current minicard view
+
2006-03-06 Harry Lu <harry.lu@sun.com>
Fix for 331550.
diff --git a/a11y/addressbook/ea-minicard-view.c b/a11y/addressbook/ea-minicard-view.c
index b66dd6585e..6ed202b867 100644
--- a/a11y/addressbook/ea-minicard-view.c
+++ b/a11y/addressbook/ea-minicard-view.c
@@ -141,21 +141,32 @@ ea_minicard_view_get_name (AtkObject *accessible)
{
EReflow *reflow;
gchar *string;
-
+ EMinicardView *card_view;
+ EBook *book = NULL;
+ const gchar *source_name;
+
g_return_val_if_fail (EA_IS_MINICARD_VIEW (accessible), NULL);
reflow = E_REFLOW(atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (accessible)));
if (!reflow)
return NULL;
-
- string = g_strdup_printf (ngettext ("current addressbook folder has %d card",
- "current addressbook folder has %d cards",
- reflow->count), reflow->count);
+ /* Get the current name of minicard view*/
+ card_view = E_MINICARD_VIEW (reflow);
+ g_object_get (card_view->adapter, "book", &book, NULL);
+ g_assert (E_IS_BOOK (book));
+ source_name = e_source_peek_name (e_book_get_source (book));
+ if (!source_name)
+ source_name="";
+
+ string = g_strdup_printf (ngettext ("current address book folder %s has %d card",
+ "current address book folder %s has %d cards",
+ reflow->count), source_name, reflow->count);
ATK_OBJECT_CLASS (parent_class)->set_name (accessible, string);
g_free (string);
+ g_object_unref(book);
return accessible->name;
}