mirror of
https://github.com/wrwrabbit/Partisan-Telegram-Android.git
synced 2026-04-29 04:29:33 +00:00
Update to 5.9.0
This commit is contained in:
parent
a9966a0353
commit
ff5735503e
365 changed files with 76570 additions and 6969 deletions
|
|
@ -19,7 +19,7 @@ import org.telegram.tgnet.TLRPC;
|
|||
|
||||
import java.io.File;
|
||||
|
||||
public class UserConfig {
|
||||
public class UserConfig extends BaseController {
|
||||
|
||||
public static int selectedAccount;
|
||||
public final static int MAX_ACCOUNT_COUNT = 3;
|
||||
|
|
@ -66,7 +66,6 @@ public class UserConfig {
|
|||
public volatile byte[] savedSaltedPassword;
|
||||
public volatile long savedPasswordTime;
|
||||
|
||||
private int currentAccount;
|
||||
private static volatile UserConfig[] Instance = new UserConfig[UserConfig.MAX_ACCOUNT_COUNT];
|
||||
public static UserConfig getInstance(int num) {
|
||||
UserConfig localInstance = Instance[num];
|
||||
|
|
@ -84,7 +83,7 @@ public class UserConfig {
|
|||
public static int getActivatedAccountsCount() {
|
||||
int count = 0;
|
||||
for (int a = 0; a < MAX_ACCOUNT_COUNT; a++) {
|
||||
if (getInstance(a).isClientActivated()) {
|
||||
if (AccountInstance.getInstance(a).getUserConfig().isClientActivated()) {
|
||||
count++;
|
||||
}
|
||||
}
|
||||
|
|
@ -92,7 +91,7 @@ public class UserConfig {
|
|||
}
|
||||
|
||||
public UserConfig(int instance) {
|
||||
currentAccount = instance;
|
||||
super(instance);
|
||||
}
|
||||
|
||||
public int getNewMessageId() {
|
||||
|
|
@ -426,7 +425,7 @@ public class UserConfig {
|
|||
resetSavedPassword();
|
||||
boolean hasActivated = false;
|
||||
for (int a = 0; a < MAX_ACCOUNT_COUNT; a++) {
|
||||
if (UserConfig.getInstance(a).isClientActivated()) {
|
||||
if (AccountInstance.getInstance(a).getUserConfig().isClientActivated()) {
|
||||
hasActivated = true;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue