diff options
author | Stephen Paul Weber <singpolyma@singpolyma.net> | 2016-01-17 16:28:38 -0500 |
---|---|---|
committer | Stephen Paul Weber <singpolyma@singpolyma.net> | 2016-01-24 17:46:08 -0500 |
commit | bf5b2f73f5a61f0a0179c9d4431579f87eecb001 (patch) | |
tree | 5bd8b9aaa8b4326dfecb699fd1cdcf97a02b8097 /src/main/java/eu/siacs/conversations/services | |
parent | ad36a4ba89f880a5522ffd5179dcaa98985e4164 (diff) |
Use a Presence class for presence information
Only has status for now, but doing it so I can add disco to it
Diffstat (limited to '')
-rw-r--r-- | src/main/java/eu/siacs/conversations/services/XmppConnectionService.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java index a295b2cee..9ad8ea1ca 100644 --- a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java +++ b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java @@ -72,6 +72,7 @@ import eu.siacs.conversations.entities.Conversation; import eu.siacs.conversations.entities.Message; import eu.siacs.conversations.entities.MucOptions; import eu.siacs.conversations.entities.MucOptions.OnRenameListener; +import eu.siacs.conversations.entities.Presence; import eu.siacs.conversations.entities.Presences; import eu.siacs.conversations.entities.Transferable; import eu.siacs.conversations.entities.TransferablePlaceholder; @@ -596,13 +597,13 @@ public class XmppConnectionService extends Service implements OnPhoneContactsLoa return getPreferences().getString("picture_compression", "auto"); } - private int getTargetPresence() { + private Presence.Status getTargetPresence() { if (xaOnSilentMode() && isPhoneSilenced()) { - return Presences.XA; + return Presence.Status.XA; } else if (awayWhenScreenOff() && !isInteractive()) { - return Presences.AWAY; + return Presence.Status.AWAY; } else { - return Presences.ONLINE; + return Presence.Status.ONLINE; } } |