aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/widgets/e-minicard-view.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-05-31 01:06:11 +0800
committerChris Lahey <clahey@src.gnome.org>2000-05-31 01:06:11 +0800
commit936611683a969d2a93bde1c41d048881e860edea (patch)
tree4d30ce4db8310ffc3fd0dfbbd6c92405b0856aa6 /addressbook/gui/widgets/e-minicard-view.c
parent016b2a545c3b3f79132f0b2fb333fbf830203eb5 (diff)
downloadgsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.tar.gz
gsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.tar.zst
gsoc2013-evolution-936611683a969d2a93bde1c41d048881e860edea.zip
Added alphabet.glade and alphabet.glade.h.
2000-05-30 Christopher James Lahey <clahey@helixcode.com> * gui/component/Makefile.am: Added alphabet.glade and alphabet.glade.h. * gui/component/addressbook.c, gui/component/alphabet.glade, gui/component/alphabet.glade.h: Added an alphabet bar. * gui/minicard/e-minicard-view.c, gui/minicard/e-minicard-view.h, gui/minicard/e-reflow-sorted.c, gui/minicard/e-reflow-sorted.h: Added the ability to just to a particular spot in the reflow. svn path=/trunk/; revision=3283
Diffstat (limited to 'addressbook/gui/widgets/e-minicard-view.c')
-rw-r--r--addressbook/gui/widgets/e-minicard-view.c30
1 files changed, 29 insertions, 1 deletions
diff --git a/addressbook/gui/widgets/e-minicard-view.c b/addressbook/gui/widgets/e-minicard-view.c
index d3acb1ad54..bc2e22fa32 100644
--- a/addressbook/gui/widgets/e-minicard-view.c
+++ b/addressbook/gui/widgets/e-minicard-view.c
@@ -107,7 +107,7 @@ e_minicard_view_init (EMinicardView *view)
view->canvas_destroy_id = 0;
gtk_object_set(GTK_OBJECT(view),
- "empty_message", _("There are no items to show in this view\n\n"
+ "empty_message", _("\n\nThere are no items to show in this view\n\n"
"Double-click here to create a new Contact."),
NULL);
@@ -380,3 +380,31 @@ e_minicard_view_remove_selection(EMinicardView *view,
}
}
}
+
+static int
+compare_to_letter(EMinicard *card, char *letter)
+{
+ g_return_val_if_fail(card != NULL, 0);
+ g_return_val_if_fail(E_IS_MINICARD(card), 0);
+
+ if (card->card) {
+ char *file_as;
+ gtk_object_get(GTK_OBJECT(card->card),
+ "file_as", &file_as,
+ NULL);
+ if (file_as)
+ return strncasecmp(file_as, letter, 1);
+ else
+ return 0;
+ } else {
+ return 0;
+ }
+}
+
+void e_minicard_view_jump_to_letter (EMinicardView *view,
+ char letter)
+{
+ e_reflow_sorted_jump(E_REFLOW_SORTED(view),
+ (GCompareFunc) compare_to_letter,
+ &letter);
+}