forked from distok/cutthecord
Compare commits
47 commits
50b3f050c4
...
38badc85d8
Author | SHA1 | Date | |
---|---|---|---|
38badc85d8 | |||
9b11df5b8a | |||
4ad1d8b1fb | |||
77a9be7f28 | |||
ab77dffe6a | |||
fce83e9ba8 | |||
3fc567f17f | |||
65e3d20105 | |||
328eac4c48 | |||
0f49fcd527 | |||
9b38cb8b5b | |||
a5e58aab0c | |||
9db51f285e | |||
042930a1b2 | |||
50bb804418 | |||
454decdc31 | |||
826cde9d44 | |||
5e8dffdcd2 | |||
230e43e4be | |||
5a282fef3f | |||
817f412c12 | |||
8518d759e1 | |||
2b89b9b6a0 | |||
2be217b2c3 | |||
359441a1f5 | |||
89a5dd1989 | |||
6c67440a91 | |||
12c11a1451 | |||
d3cbb7c760 | |||
45947d7e78 | |||
bf679ad046 | |||
ee77823392 | |||
4bc5ffc081 | |||
41ef69968d | |||
458d5f4225 | |||
91b6f28d2d | |||
e46d01f9f3 | |||
1f69ccf301 | |||
51f1e9079b | |||
38ac8b7bc2 | |||
724cb64be8 | |||
e8b6b3e629 | |||
c8c7520853 | |||
aeac528a16 | |||
1066c3c5a6 | |||
4bf12e1e2b | |||
e464c9a283 |
492 changed files with 1108592 additions and 10 deletions
|
@ -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 *
|
||||
|
|
|
@ -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?
|
||||
|
|
43
old-patches/customdefaultemoji/1011.patch
Normal file
43
old-patches/customdefaultemoji/1011.patch
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/1012.patch
Normal file
43
old-patches/customdefaultemoji/1012.patch
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/1013.patch-failed
Normal file
43
old-patches/customdefaultemoji/1013.patch-failed
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/991.patch
Normal file
43
old-patches/customdefaultemoji/991.patch
Normal file
|
@ -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
|
||||
|
80
old-patches/customdefaultemoji/991.patch-failed
Normal file
80
old-patches/customdefaultemoji/991.patch-failed
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/992.patch
Normal file
43
old-patches/customdefaultemoji/992.patch
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/993.patch
Normal file
43
old-patches/customdefaultemoji/993.patch
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/994.patch
Normal file
43
old-patches/customdefaultemoji/994.patch
Normal file
|
@ -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
|
||||
|
43
old-patches/customdefaultemoji/996.patch
Normal file
43
old-patches/customdefaultemoji/996.patch
Normal file
|
@ -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
|
||||
|
190
old-patches/smalltime/992.patch
Normal file
190
old-patches/smalltime/992.patch
Normal file
|
@ -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 a new issue