aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-07-01 00:21:18 +0800
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-07-01 01:21:29 +0800
commitd57d431db13fa5fdbddc51d71b9f82da00418522 (patch)
tree9d546eea32bdfdb810427f994d71d22889d73d60
parent941d757434d220fec709f30ac4847c7240b3d7d3 (diff)
downloadgsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar.gz
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar.bz2
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar.lz
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar.xz
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.tar.zst
gsoc2013-empathy-d57d431db13fa5fdbddc51d71b9f82da00418522.zip
Always react when disconnecting from the network
-rw-r--r--libempathy/empathy-idle.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libempathy/empathy-idle.c b/libempathy/empathy-idle.c
index 78366e021..1686555ff 100644
--- a/libempathy/empathy-idle.c
+++ b/libempathy/empathy-idle.c
@@ -244,8 +244,7 @@ idle_nm_state_change_cb (NMClient *client,
priv = GET_PRIV (idle);
- if (!priv->use_nm
- || priv->nm_saved_state == TP_CONNECTION_PRESENCE_TYPE_UNSET) {
+ if (!priv->use_nm) {
return;
}
@@ -266,7 +265,8 @@ idle_nm_state_change_cb (NMClient *client,
priv->nm_saved_status = g_strdup (priv->status);
empathy_idle_set_state (idle, TP_CONNECTION_PRESENCE_TYPE_OFFLINE);
}
- else if (!old_nm_connected && new_nm_connected) {
+ else if (!old_nm_connected && new_nm_connected
+ && priv->nm_saved_state != TP_CONNECTION_PRESENCE_TYPE_UNSET) {
/* We are now connected */
DEBUG ("Reconnected: Restore state %d (%s)",
priv->nm_saved_state, priv->nm_saved_status);