diff options
author | Niels De Graef <nielsdegraef@gmail.com> | 2018-04-02 13:24:53 +0200 |
---|---|---|
committer | Niels De Graef <nielsdegraef@gmail.com> | 2018-04-02 15:07:56 +0200 |
commit | d00865bc2c4ce4508fc3cdc0226be542b17f1788 (patch) | |
tree | 6f8e609beb08849019984b6ba6fdf1d0d42ea179 /src/contacts-contact-list.vala | |
parent | db84afdd50bc8d45a0dcf7114881a9a23819445f (diff) | |
download | gnome-contacts-d00865bc2c4ce4508fc3cdc0226be542b17f1788.tar.gz |
Contact: make hidden a property & cleanup the code.
Diffstat (limited to 'src/contacts-contact-list.vala')
-rw-r--r-- | src/contacts-contact-list.vala | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/contacts-contact-list.vala b/src/contacts-contact-list.vala index 2696002..08fa8a3 100644 --- a/src/contacts-contact-list.vala +++ b/src/contacts-contact-list.vala @@ -38,6 +38,7 @@ public class Contacts.ContactList : ListBox { public ContactDataRow(Contact c) { this.contact = c; this.contact.changed.connect (on_contact_changed); + this.contact.notify["hidden"].connect ((o, p) => changed()); get_style_context (). add_class ("contact-data-row"); @@ -240,7 +241,7 @@ public class Contacts.ContactList : ListBox { private bool filter_row (ListBoxRow row) { var contact = ((ContactDataRow) row).contact; - return !contact.is_hidden && this.filter_query.is_match (contact.individual) > 0; + return !contact.hidden && this.filter_query.is_match (contact.individual) > 0; } public void select_contact (Contact? contact) { |