aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2015-02-12 18:52:10 +0100
committeriNPUTmice <daniel@gultsch.de>2015-02-12 18:52:10 +0100
commit45de788773ffc62bd936fa9b4a5ca81a5a5c6010 (patch)
tree1e2ca29e343a83846734c9df19f3d4776608318b /src/main/java
parent44ee7466816378eb4fc6b2bff2e4fa001c3b08a0 (diff)
use time instead of uptime for unmute
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/eu/siacs/conversations/entities/Conversation.java3
-rw-r--r--src/main/java/eu/siacs/conversations/ui/ConversationActivity.java4
2 files changed, 2 insertions, 5 deletions
diff --git a/src/main/java/eu/siacs/conversations/entities/Conversation.java b/src/main/java/eu/siacs/conversations/entities/Conversation.java
index 036acf63..71c2523e 100644
--- a/src/main/java/eu/siacs/conversations/entities/Conversation.java
+++ b/src/main/java/eu/siacs/conversations/entities/Conversation.java
@@ -626,8 +626,7 @@ public class Conversation extends AbstractEntity implements Blockable {
}
public boolean isMuted() {
- return SystemClock.elapsedRealtime() < this.getLongAttribute(
- ATTRIBUTE_MUTED_TILL, 0);
+ return System.currentTimeMillis() < this.getLongAttribute(ATTRIBUTE_MUTED_TILL, 0);
}
public boolean setAttribute(String key, String value) {
diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
index 0a55c6b5..d9e6ffb8 100644
--- a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
+++ b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
@@ -12,7 +12,6 @@ import android.content.IntentSender.SendIntentException;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
-import android.os.SystemClock;
import android.provider.MediaStore;
import android.support.v4.widget.SlidingPaneLayout;
import android.support.v4.widget.SlidingPaneLayout.PanelSlideListener;
@@ -677,8 +676,7 @@ public class ConversationActivity extends XmppActivity
if (durations[which] == -1) {
till = Long.MAX_VALUE;
} else {
- till = SystemClock.elapsedRealtime()
- + (durations[which] * 1000);
+ till = System.currentTimeMillis() + (durations[which] * 1000);
}
conversation.setMutedTill(till);
ConversationActivity.this.xmppConnectionService.databaseBackend