1
0
Fork 0
mirror of https://gitlab.gnome.org/GNOME/calls.git synced 2024-09-28 14:55:26 +00:00
Commit graph

27 commits

Author SHA1 Message Date
Evangelos Ribeiro Tzaras
f7dd62c0bd contacts-provider: Disconnect signals on finalize 2023-04-18 08:34:39 +00:00
Evangelos Ribeiro Tzaras
830906f57a contacts-provider: Handle NULL and empty strings graceful in lookup
Fixes a crash where we asserted on best match when the id was NULL or
empty.

Closes: #567
2023-04-13 06:01:05 +00:00
Evangelos Ribeiro Tzaras
10d74634ba contacts-provider: Simplify refcounting in lookup_id()
g_autoptr usage was a bit pointless here since
calls_contacts_provider_lookup_id() is transfer full
2023-04-13 06:01:05 +00:00
Evangelos Ribeiro Tzaras
bb6b76107c build: Rename util.{c,h} to calls-util.{c,h}
"util" is a very generic name. This guards against accidentally
including similarly named headers from elsewhere.
2023-01-22 07:33:02 +00:00
Evangelos Ribeiro Tzaras
9b49b0bc4f contacts-provider: Use STR_IS_NULL_OR_EMPTY macro 2023-01-22 07:33:02 +00:00
Evangelos Ribeiro Tzaras
b799605d01 contacts-provider: Codestyle 2023-01-22 07:33:02 +00:00
Evangelos Ribeiro Tzaras
79401f6227 contact-provider: Allow can-add-contacts to be reset
Under normal conditions it is not expected that whether we can add
contacts or not (based on the presence of the appropriate action on
gnome-contacts) changes.

Nevertheless it can be beneficial for debugging when installing patched
and unpatched versions of gnome-contacts.
2022-11-08 11:28:18 +00:00
Evangelos Ribeiro Tzaras
b948629274 contacts-provider: Remove unused variable 2022-11-08 11:28:18 +00:00
Evangelos Ribeiro Tzaras
94fa13af4c settings: Convert to the singleton pattern
We only have a single source of settings, so we should reflect that by
using a singleton. This also reduces our LoC.

This doesn't impair our ability to run tests because there we run with
GSETTINGS_BACKEND=memory
2022-05-13 19:58:07 +02:00
Evangelos Ribeiro Tzaras
7ac862155b Uncrustify sources
Ran `find src plugins -iname '*.[c|h]' -print0 | xargs -0 uncrustify --no-backup`
with some minimal manual intervention.
2022-04-24 12:59:42 +02:00
Evangelos Ribeiro Tzaras
9ffcbe2de8 contacts-provider: Don't throw a critical when trying to lookup NULL id
Anonymous callers will show up with a NULL id, so don't emit a critical here.

Fixes 006673a9e1
2022-02-18 10:55:53 +01:00
Evangelos Ribeiro Tzaras
006673a9e1 contacts-provider: Guard against lookup with NULL id
If the id is NULL g_str_hash(NULL) will be called which tries dereferencing the
pointer.

Fixes #408
2022-02-15 08:02:18 +01:00
Evangelos Ribeiro Tzaras
c0a67d2cce contacts-provider: Remove static from action name string
There was no reason to have it static in the first place.
2022-01-20 10:23:09 +00:00
Evangelos Ribeiro Tzaras
12ae596352 contacts-provider: Overhaul documentation
This commit describes what CallsContactsProvider is used for,
documents signals, properties and the public API.
2022-01-20 10:17:26 +01:00
Evangelos Ribeiro Tzaras
5588bd934a contacts-provider: Add API to add new contacts 2022-01-18 02:12:37 +00:00
Evangelos Ribeiro Tzaras
c6d867cd72 contacts-provider: Add GDBusActionGroup to query if contacts can be added
As this requires a patched GNOME Contacts, we want to be able to query if the
necessary actions to add new contacts is available before trying to use it.
2022-01-18 02:12:37 +00:00
Evangelos Ribeiro Tzaras
56da32d1b6 contacts-provider: Remove unused config.h include 2022-01-18 02:12:37 +00:00
Evangelos Ribeiro Tzaras
8ad21b211c contacts-provider: Codestyle 2022-01-18 02:12:37 +00:00
Evangelos Ribeiro Tzaras
bc4ed210b2 contacts-provider: Sort includes 2022-01-18 02:12:37 +00:00
Evangelos Ribeiro Tzaras
f206b7d257 call: Rename property from "number" to "id"
The term number is not necessarily accurate when dealing with f.e. SIP.
2021-12-05 09:49:05 +01:00
Evangelos Ribeiro Tzaras
33ad4dbe86 Simplify country code handling 2021-09-27 08:46:09 +00:00
Evangelos Ribeiro Tzaras
5ed24c4ed7 doc: Fix gtk-doc transfer annotations 2021-04-27 11:38:26 +02:00
Evangelos Ribeiro Tzaras
0bd6d7f2a5 best-match: Lookup contact if country code changed
Closes #217
2021-04-06 14:27:26 +00:00
Evangelos Ribeiro Tzaras
f8a57edc6d contacts-provider: fix docstring
The caller takes ownership of the returned `CallsBestMatch`, so
this should be reflected in the docstring
2021-04-06 14:27:26 +00:00
Evangelos Ribeiro Tzaras
32c89ca9dd contact-provider: remove trailing whitespaces 2021-04-06 14:27:26 +00:00
Julian Sparber
d75d39dc66 BestMatch: Move SearchView creation inside the class 2021-02-03 23:58:31 +00:00
Julian Sparber
4ba9feb22f ContactsProvider: Add contacts provider
The CallsContacts provider offers a GListModel that can be connected
directly to a GtkListBox for showing a contacts list.
2021-02-03 16:18:29 +00:00