[empathy] Geoclue doesn't like NONE as an accuracy level
- From: Pierre-Luc Beaudoin <plbeaudoin src gnome org>
- To: svn-commits-list gnome org
- Subject: [empathy] Geoclue doesn't like NONE as an accuracy level
- Date: Tue, 9 Jun 2009 14:43:23 -0400 (EDT)
commit 39c0f4468521deaa00f4db3e891cd20992aa96c9
Author: Pierre-Luc Beaudoin <pierre-luc beaudoin collabora co uk>
Date: Mon Jun 8 18:37:47 2009 -0400
Geoclue doesn't like NONE as an accuracy level
Possibly a bug in Geoclue, but passing COUNTRY instead of NONE as
the minimum accuracy required gives better results (ie more providers
are possible).
---
libempathy-gtk/empathy-location-manager.c | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/libempathy-gtk/empathy-location-manager.c b/libempathy-gtk/empathy-location-manager.c
index fb80431..1b76e2e 100644
--- a/libempathy-gtk/empathy-location-manager.c
+++ b/libempathy-gtk/empathy-location-manager.c
@@ -302,7 +302,10 @@ address_changed_cb (GeoclueAddress *address,
g_hash_table_remove (priv->location, EMPATHY_LOCATION_POSTAL_CODE);
if (g_hash_table_size (details) == 0)
- return;
+ {
+ DEBUG ("\t - (Empty)");
+ return;
+ }
g_hash_table_iter_init (&iter, details);
while (g_hash_table_iter_next (&iter, &key, &value))
@@ -449,8 +452,11 @@ update_resources (EmpathyLocationManager *location_manager)
DEBUG ("Updating resources %d", priv->resources);
+ /* As per Geoclue bug #15126, using NONE results in no address
+ * being found as geoclue-manual report an empty address with
+ * accuracy = NONE */
if (!geoclue_master_client_set_requirements (priv->gc_client,
- GEOCLUE_ACCURACY_LEVEL_NONE, 0, TRUE, priv->resources,
+ GEOCLUE_ACCURACY_LEVEL_COUNTRY, 0, TRUE, priv->resources,
NULL))
{
DEBUG ("set_requirements failed");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]