diff options
author | Emmanuel ROHEE <erohee@amdocs.com> | 2014-08-29 15:29:26 +0200 |
---|---|---|
committer | Emmanuel ROHEE <erohee@amdocs.com> | 2014-08-29 15:29:26 +0200 |
commit | bf6466f02a6ffd7d73f6e0506115e611540d0cb7 (patch) | |
tree | 584a464720b0db672b68d7538ea28514d5a1e206 /webclient | |
parent | Only show voice call button if there are exactly 2 members in the room. Also ... (diff) | |
download | synapse-bf6466f02a6ffd7d73f6e0506115e611540d0cb7.tar.xz |
The away state is unavailable not offline
Diffstat (limited to 'webclient')
-rw-r--r-- | webclient/components/matrix/presence-service.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/webclient/components/matrix/presence-service.js b/webclient/components/matrix/presence-service.js index 6a1edcaf43..555118133b 100644 --- a/webclient/components/matrix/presence-service.js +++ b/webclient/components/matrix/presence-service.js @@ -23,9 +23,9 @@ angular.module('mPresence', []) .service('mPresence', ['$timeout', 'matrixService', function ($timeout, matrixService) { - // Time in ms after that a user is considered as offline/away - var OFFLINE_TIME = 5 * 60000; // 5 mins - + // Time in ms after that a user is considered as unavailable/away + var UNAVAILABLE_TIME = 5 * 60000; // 5 mins + // The current presence state var state = undefined; @@ -88,11 +88,11 @@ angular.module('mPresence', []) }; /** - * Callback called when the user made no action on the page for OFFLINE_TIME ms. + * Callback called when the user made no action on the page for UNAVAILABLE_TIME ms. * @private */ - function onOfflineTimerFire() { - self.setState(matrixService.presence.offline); + function onUnvailableTimerFire() { + self.setState(matrixService.presence.unavailable); } /** @@ -105,7 +105,7 @@ angular.module('mPresence', []) // Re-arm the timer $timeout.cancel(timer); - timer = $timeout(onOfflineTimerFire, OFFLINE_TIME); + timer = $timeout(onUnvailableTimerFire, UNAVAILABLE_TIME); } }]); |