forked from distok/cutthecord
Compare commits
47 Commits
50b3f050c4
...
38badc85d8
Author | SHA1 | Date |
---|---|---|
eatsfoobars | 38badc85d8 | |
eatsfoobars | 9b11df5b8a | |
eatsfoobars | 4ad1d8b1fb | |
eatsfoobars | 77a9be7f28 | |
eatsfoobars | ab77dffe6a | |
ave | fce83e9ba8 | |
juby210-PL | 3fc567f17f | |
ave | 65e3d20105 | |
eatsfoobars | 328eac4c48 | |
eatsfoobars | 0f49fcd527 | |
eatsfoobars | 9b38cb8b5b | |
ave | a5e58aab0c | |
ave | 9db51f285e | |
eatsfoobars | 042930a1b2 | |
ave | 50bb804418 | |
ave | 454decdc31 | |
ave | 826cde9d44 | |
eatsfoobars | 5e8dffdcd2 | |
ave | 230e43e4be | |
eatsfoobars | 5a282fef3f | |
ave | 817f412c12 | |
ave | 8518d759e1 | |
ave | 2b89b9b6a0 | |
ave | 2be217b2c3 | |
ave | 359441a1f5 | |
ave | 89a5dd1989 | |
ave | 6c67440a91 | |
eatsfoobars | 12c11a1451 | |
ave | d3cbb7c760 | |
eatsfoobars | 45947d7e78 | |
ave | bf679ad046 | |
ave | ee77823392 | |
ave | 4bc5ffc081 | |
ave | 41ef69968d | |
ave | 458d5f4225 | |
ave | 91b6f28d2d | |
ave | e46d01f9f3 | |
ave | 1f69ccf301 | |
ave | 51f1e9079b | |
ave | 38ac8b7bc2 | |
eatsfoobars | 724cb64be8 | |
ave | e8b6b3e629 | |
ave | c8c7520853 | |
ave | aeac528a16 | |
ave | 1066c3c5a6 | |
ave | 4bf12e1e2b | |
eatsfoobars | e464c9a283 |
|
@ -2,7 +2,7 @@
|
|||
|
||||
Modular Client Mod for Discord's Android app.
|
||||
|
||||
**Latest supported Discord Android version:** 9.9.2 (992), released on 2019-11-26.
|
||||
**Latest supported Discord Android version:** 10.2.9 (1029), released on 2020-01-28.
|
||||
|
||||
New patch development will be done for the latest supported version.
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
import os
|
||||
import sys
|
||||
import shutil
|
||||
import requests
|
||||
import json
|
||||
import subprocess
|
||||
from ctcconfig import *
|
||||
|
@ -231,9 +232,9 @@ APK_PATH = os.path.join(WORK_FOLDER, "discord",
|
|||
|
||||
# Sign the APK
|
||||
if DO_APKSIGNER:
|
||||
subprocess.run(f"apksigner sign --ks {KEYSTORE_FILE}"
|
||||
subprocess.run(f"apksigner sign --ks {KEYSTORE_FILE} "
|
||||
f"--ks-key-alias {KEYSTORE_ALIAS} "
|
||||
f"--ks-pass pass:{KEYSTORE_PASS}"
|
||||
f"--ks-pass pass:{KEYSTORE_PASS} "
|
||||
f"{APK_PATH}",
|
||||
shell=True,
|
||||
cwd=WORK_FOLDER)
|
||||
|
|
|
@ -7,3 +7,5 @@ Here's why these patches are no longer maintained in this form:
|
|||
- notyping: Moved into slashcommands as a slash command
|
||||
- pureevil: It's now upstream (yay.)
|
||||
- compact: It's just a pain to maintain.
|
||||
- smalltime: It's just a pain to maintain.
|
||||
- customdefaultemoji: There doesn't seem to be default emojis anymore?
|
||||
|
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,80 @@
|
|||
diff -crB from/smali/com/discord/stores/StoreEmoji.smali to/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** from/smali/com/discord/stores/StoreEmoji.smali 2019-11-14 22:32:21.079850865 +0300
|
||||
--- to/smali/com/discord/stores/StoreEmoji.smali 2019-11-14 22:33:18.846833515 +0300
|
||||
***************
|
||||
*** 103,139 ****
|
||||
|
||||
const/4 v1, 0x0
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x1
|
||||
|
||||
! const-string v2, "ok_hand"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x2
|
||||
|
||||
! const-string v2, "eyes"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x3
|
||||
|
||||
! const-string v2, "sweat_drops"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x4
|
||||
|
||||
! const-string v2, "joy"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x5
|
||||
|
||||
! const-string v2, "pig"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
--- 103,139 ----
|
||||
|
||||
const/4 v1, 0x0
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x1
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x2
|
||||
|
||||
! const-string v2, "ok_hand"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x3
|
||||
|
||||
! const-string v2, "eyes"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x4
|
||||
|
||||
! const-string v2, "sweat_drops"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
||||
const/4 v1, 0x5
|
||||
|
||||
! const-string v2, "joy"
|
||||
|
||||
aput-object v2, v0, v1
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff -crB com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali com.discord-992/smali/com/discord/stores/StoreEmoji.smali
|
||||
*** com.discord-992-base/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 10:48:46.036158964 +0300
|
||||
--- com.discord-992/smali/com/discord/stores/StoreEmoji.smali 2019-11-26 12:08:01.403160008 +0300
|
||||
***************
|
||||
*** 97,113 ****
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "thinking"
|
||||
|
||||
! const-string v3, "ok_hand"
|
||||
|
||||
! const-string v4, "eyes"
|
||||
|
||||
! const-string v5, "sweat_drops"
|
||||
|
||||
! const-string v6, "joy"
|
||||
|
||||
! const-string v7, "pig"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
--- 97,113 ----
|
||||
|
||||
sput-object v0, Lcom/discord/stores/StoreEmoji;->Companion:Lcom/discord/stores/StoreEmoji$Companion;
|
||||
|
||||
! const-string v2, "star"
|
||||
|
||||
! const-string v3, "thinking"
|
||||
|
||||
! const-string v4, "ok_hand"
|
||||
|
||||
! const-string v5, "eyes"
|
||||
|
||||
! const-string v6, "sweat_drops"
|
||||
|
||||
! const-string v7, "joy"
|
||||
|
||||
.line 350
|
||||
filled-new-array/range {v2 .. v7}, [Ljava/lang/String;
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.orig
|
||||
Only in com.discord-992/smali/com/discord/stores: StoreEmoji.smali.rej
|
||||
|
|
@ -38,4 +38,12 @@ This patch changes default list of custom emojis.
|
|||
- 9.8.6
|
||||
- 9.9.1
|
||||
- 9.9.2
|
||||
- 9.9.3
|
||||
- 9.9.4
|
||||
- 9.9.6
|
||||
- 10.0.6
|
||||
- 10.0.7
|
||||
- 10.1.1
|
||||
- 10.1.2
|
||||
- 10.1.3
|
||||
|
|
@ -0,0 +1,190 @@
|
|||
diff -crB from/smali_classes2/com/miguelgaeta/simple_time/SimpleTime.smali to/smali_classes2/com/miguelgaeta/simple_time/SimpleTime.smali
|
||||
*** from/smali_classes2/com/miguelgaeta/simple_time/SimpleTime.smali 2019-05-12 12:13:48.187878981 +0300
|
||||
--- to/smali_classes2/com/miguelgaeta/simple_time/SimpleTime.smali 2019-05-12 12:15:32.663889927 +0300
|
||||
***************
|
||||
*** 239,411 ****
|
||||
.end method
|
||||
|
||||
.method public toReadableTimeString(Ljava/lang/Long;)Ljava/lang/String;
|
||||
! .locals 6
|
||||
!
|
||||
! .line 126
|
||||
! invoke-virtual {p0}, Lcom/miguelgaeta/simple_time/SimpleTime;->currentTimeMillis()J
|
||||
!
|
||||
! move-result-wide v0
|
||||
!
|
||||
! invoke-static {v0, v1}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
||||
!
|
||||
! move-result-object v0
|
||||
!
|
||||
! invoke-virtual {p0, v0}, Lcom/miguelgaeta/simple_time/SimpleTime;->toCalendar(Ljava/lang/Long;)Ljava/util/Calendar;
|
||||
!
|
||||
! move-result-object v0
|
||||
!
|
||||
! const/4 v1, 0x0
|
||||
!
|
||||
! const/16 v2, 0xb
|
||||
!
|
||||
! .line 128
|
||||
! invoke-virtual {v0, v2, v1}, Ljava/util/Calendar;->set(II)V
|
||||
!
|
||||
! const/16 v2, 0xc
|
||||
!
|
||||
! .line 129
|
||||
! invoke-virtual {v0, v2, v1}, Ljava/util/Calendar;->set(II)V
|
||||
!
|
||||
! const/16 v2, 0xd
|
||||
!
|
||||
! .line 130
|
||||
! invoke-virtual {v0, v2, v1}, Ljava/util/Calendar;->set(II)V
|
||||
!
|
||||
! const/16 v2, 0xe
|
||||
!
|
||||
! .line 131
|
||||
! invoke-virtual {v0, v2, v1}, Ljava/util/Calendar;->set(II)V
|
||||
!
|
||||
! .line 133
|
||||
! iget-object v1, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->locale:Ljava/util/Locale;
|
||||
!
|
||||
! invoke-virtual {v1}, Ljava/util/Locale;->getLanguage()Ljava/lang/String;
|
||||
!
|
||||
! move-result-object v1
|
||||
!
|
||||
! const-string v2, "en"
|
||||
!
|
||||
! invoke-virtual {v1, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
|
||||
!
|
||||
! move-result v1
|
||||
!
|
||||
! if-nez v1, :cond_1
|
||||
!
|
||||
! .line 136
|
||||
! invoke-virtual {p1}, Ljava/lang/Long;->longValue()J
|
||||
!
|
||||
! move-result-wide v1
|
||||
!
|
||||
! invoke-virtual {v0}, Ljava/util/Calendar;->getTimeInMillis()J
|
||||
!
|
||||
! move-result-wide v3
|
||||
!
|
||||
! cmp-long v0, v1, v3
|
||||
!
|
||||
! if-lez v0, :cond_0
|
||||
!
|
||||
! .line 137
|
||||
iget-object v0, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterTime:Ljava/text/DateFormat;
|
||||
|
||||
invoke-virtual {v0, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
|
||||
- move-result-object p1
|
||||
-
|
||||
- return-object p1
|
||||
-
|
||||
- .line 139
|
||||
- :cond_0
|
||||
- iget-object v0, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterDateTime:Ljava/text/DateFormat;
|
||||
-
|
||||
- invoke-virtual {v0, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
-
|
||||
- move-result-object p1
|
||||
-
|
||||
- return-object p1
|
||||
-
|
||||
- .line 143
|
||||
- :cond_1
|
||||
- invoke-virtual {p1}, Ljava/lang/Long;->longValue()J
|
||||
-
|
||||
- move-result-wide v1
|
||||
-
|
||||
- invoke-virtual {v0}, Ljava/util/Calendar;->getTimeInMillis()J
|
||||
-
|
||||
- move-result-wide v3
|
||||
-
|
||||
- cmp-long v5, v1, v3
|
||||
-
|
||||
- if-lez v5, :cond_2
|
||||
-
|
||||
- .line 144
|
||||
- new-instance v0, Ljava/lang/StringBuilder;
|
||||
-
|
||||
- const-string v1, "Today at "
|
||||
-
|
||||
- invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
||||
-
|
||||
- iget-object v1, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterTime:Ljava/text/DateFormat;
|
||||
-
|
||||
- invoke-virtual {v1, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
-
|
||||
- move-result-object p1
|
||||
-
|
||||
- invoke-virtual {v0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
-
|
||||
- invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
||||
-
|
||||
- move-result-object p1
|
||||
-
|
||||
- return-object p1
|
||||
-
|
||||
- :cond_2
|
||||
- const/4 v1, 0x5
|
||||
-
|
||||
- const/4 v2, -0x1
|
||||
-
|
||||
- .line 147
|
||||
- invoke-virtual {v0, v1, v2}, Ljava/util/Calendar;->add(II)V
|
||||
-
|
||||
- .line 149
|
||||
- invoke-virtual {p1}, Ljava/lang/Long;->longValue()J
|
||||
-
|
||||
- move-result-wide v1
|
||||
-
|
||||
- invoke-virtual {v0}, Ljava/util/Calendar;->getTimeInMillis()J
|
||||
-
|
||||
- move-result-wide v3
|
||||
-
|
||||
- cmp-long v0, v1, v3
|
||||
-
|
||||
- if-lez v0, :cond_3
|
||||
-
|
||||
- .line 150
|
||||
- new-instance v0, Ljava/lang/StringBuilder;
|
||||
-
|
||||
- const-string v1, "Yesterday at "
|
||||
-
|
||||
- invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
||||
-
|
||||
- iget-object v1, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterTime:Ljava/text/DateFormat;
|
||||
-
|
||||
- invoke-virtual {v1, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
-
|
||||
- move-result-object p1
|
||||
-
|
||||
- invoke-virtual {v0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
-
|
||||
- invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
||||
-
|
||||
- move-result-object p1
|
||||
-
|
||||
- return-object p1
|
||||
-
|
||||
- .line 153
|
||||
- :cond_3
|
||||
- iget-object v0, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterDateTime:Ljava/text/DateFormat;
|
||||
-
|
||||
- invoke-virtual {v0, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
-
|
||||
move-result-object p1
|
||||
|
||||
return-object p1
|
||||
--- 239,249 ----
|
||||
.end method
|
||||
|
||||
.method public toReadableTimeString(Ljava/lang/Long;)Ljava/lang/String;
|
||||
! .locals 1
|
||||
iget-object v0, p0, Lcom/miguelgaeta/simple_time/SimpleTime;->formatterTime:Ljava/text/DateFormat;
|
||||
|
||||
invoke-virtual {v0, p1}, Ljava/text/DateFormat;->format(Ljava/lang/Object;)Ljava/lang/String;
|
||||
|
||||
move-result-object p1
|
||||
|
||||
return-object p1
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue