Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

osso-abook-contact-field: if no telepathy account is availbe to handel tel and sms, try hildon-mime. #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

IMbackK
Copy link

@IMbackK IMbackK commented Sep 27, 2023

This allows abook to be more useful with non-telepathy dialers such as sphone-ofono or phosh calls

…e tel and sms, try hildon-mime.

This allows abook to be more useful with non-telepathy dialers such as sphone-ofono or phosh calls
@IMbackK
Copy link
Author

IMbackK commented Sep 27, 2023

this requires maemo-leste/libhildonmime#5

{
if (TP_IS_ACCOUNT(account))
{
rv = request_channel(account, OSSO_ABOOK_CONTACT_ACTION_TEL,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rv = request_channel(account, OSSO_ABOOK_CONTACT_ACTION_SMS, values->data, &error);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same "better code" note as above

@@ -4715,11 +4737,34 @@ osso_abook_contact_action_start_with_callback(
if (contact_action_mmicode(data, values->data))
return TRUE;

rv = request_channel(account, OSSO_ABOOK_CONTACT_ACTION_TEL,
if (TP_IS_ACCOUNT(account))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think a better code would be:

if (TP_IS_ACCOUNT(account))
rv = request_channel(account, OSSO_ABOOK_CONTACT_ACTION_TEL, values->data, &error);

if (!rv)
rv = contact_action_tel_as_uri(parent, values->data);

contact_action_tel_as_uri(GtkWindow *parent, const char *line_id)
{
gchar *uri = g_strconcat("tel://", line_id, NULL);
HildonURIAction *action = hildon_uri_get_xdg_action();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure we shall prefer xdg-open here, lets leave libhidonmime decide for us

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants