diff options
author | Jon Trowbridge <trow@ximian.com> | 2001-06-30 13:23:09 +0800 |
---|---|---|
committer | Jon Trowbridge <trow@src.gnome.org> | 2001-06-30 13:23:09 +0800 |
commit | 7c5dd95cd7aefa8243edac3c67bf1910fc905c4e (patch) | |
tree | 5c8dc3c28a6bac7d3e1643e9cdcfb0b75f28ebbc /addressbook/backend/ebook/e-card.h | |
parent | c187a911c8926429946cc385fd5f7c8f0932d3e3 (diff) | |
download | gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar.gz gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar.bz2 gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar.lz gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar.xz gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.tar.zst gsoc2013-evolution-7c5dd95cd7aefa8243edac3c67bf1910fc905c4e.zip |
Make the standard for considering two cards to be match stricter.
2001-06-30 Jon Trowbridge <trow@ximian.com>
* gui/merging/e-card-merging.c (match_query_callback): Make the
standard for considering two cards to be match stricter.
* gui/component/select-names/e-select-names-completion.c
(make_match): Use the card's use-score to set the match's
sort_major value.
(match_name): Removed obsolete code.
(e_select_names_completion_begin): Added (double) cast to make
match->score calculation come out properly.
* backend/ebook/e-card.c: Added X-EVOLUTION-LAST-USE and
X-EVOLUTION-USE-SCORE to attribute_jump_array.
(e_card_get_today): Added. A convenience routine for getting
today's date and putting it in a GDate.
(e_card_get_use_score): Added. Compute the current, time-decayed,
use-score for the card.
(e_card_touch): Increment the use-score by one; update the last
used date.
(e_card_date_to_string): Added as a convenience routine, getting
rid of some code duplication.
(e_card_get_vobject): Add handlers for X-EVOLUTION-USE-SCORE and
X-EVOLUTION-LAST-USE.
(parse_last_use): Added.
(parse_use_score): Added.
(e_card_class_init): Added args for last-use and use-score.
(e_card_get_arg): Added handlers for last-use and use-score.
o
(e_card_set_arg): Added handlers for last-use and use-score.
* backend/ebook/e-destination.c: Added pending_card_id to
EDestinationPrivate struct.
(e_destination_copy): Copy the pending_card_id.
(e_destination_is_empty): Check for a pending_card_id. We are
non-empty if we have one.
(e_destination_clear_card): Clear pending_card_id.
(e_destination_set_card): Clear pending_card_id.
(e_destination_has_pending_card): Added.
(e_destination_use_card): Added. An asynchronous way to load a
pending card and then apply a callback to it.
(build_field): Be paranoid, map our special characters to '_'.
(e_destination_export): Use EXPORT_MAX_FIELDS symbol rather than a
hard-wired array size. Added the "card" entry.
(e_destination_import): Fix bug in handling of the "name" field.
Process the "card" field.
(e_destination_touch): "Touch" and commit the ECard corresponding
to the e-mail address in the destination. (A query against the
local addressbook is actually performed, in case the destination
isn't cardified.
* backend/ebook/e-card-compare.c (e_card_compare_name): Revamp the
way E_CARD_MATCH_FOO results are mapped to comparison results.
Report better matches when the family name is matched.
svn path=/trunk/; revision=10626
Diffstat (limited to 'addressbook/backend/ebook/e-card.h')
-rw-r--r-- | addressbook/backend/ebook/e-card.h | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/addressbook/backend/ebook/e-card.h b/addressbook/backend/ebook/e-card.h index 78c6f3d661..d43f0666c2 100644 --- a/addressbook/backend/ebook/e-card.h +++ b/addressbook/backend/ebook/e-card.h @@ -34,12 +34,12 @@ struct _ECard { char *file_as; /* The File As field. */ char *fname; /* The full name. */ ECardName *name; /* The structured name. */ - EList *address; /* Delivery addresses (ECardDeliveryAddress *) */ - EList *address_label; /* Delivery address labels + EList *address; /* Delivery addresses (ECardDeliveryAddress *) */ + EList *address_label; /* Delivery address labels * (ECardAddrLabel *) */ - EList *phone; /* Phone numbers (ECardPhone *) */ - EList *email; /* Email addresses (char *) */ + EList *phone; /* Phone numbers (ECardPhone *) */ + EList *email; /* Email addresses (char *) */ char *url; /* The person's web page. */ ECardDate *bday; /* The person's birthday. */ @@ -67,13 +67,17 @@ struct _ECard { gint timezone; /* number of minutes from UTC as an int */ - EList *categories; /* Categories. */ + ECardDate *last_use; + float raw_use_score; - EList *arbitrary; /* Arbitrary fields. */ + EList *categories; /* Categories. */ - guint32 wants_html : 1; /* Wants html mail. */ - guint32 wants_html_set : 1; /* Wants html mail. */ + EList *arbitrary; /* Arbitrary fields. */ + + + guint32 wants_html : 1; /* Wants html mail. */ + guint32 wants_html_set : 1; /* Wants html mail. */ guint32 list : 1; /* If the card corresponds to a contact list */ guint32 list_show_addresses : 1; /* Whether to show the addresses in the To: or Bcc: field */ @@ -119,6 +123,9 @@ char *e_card_get_vcard (ECard char *e_card_list_get_vcard (GList *list); ECard *e_card_duplicate (ECard *card); +float e_card_get_use_score (ECard *card); +void e_card_touch (ECard *card); + /* Evolution List convenience functions */ gboolean e_card_evolution_list (ECard *card); gboolean e_card_evolution_list_show_addresses(ECard *card); |