-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathAppSingleton_1.5.2.java
More file actions
97 lines (92 loc) · 3.44 KB
/
AppSingleton_1.5.2.java
File metadata and controls
97 lines (92 loc) · 3.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
/*
* Decompiled with JADX v0.9.0.
*/
package it.deviato.spotifuck;
import Q0.e;
import R0.a;
import R0.c;
import R0.g;
import android.app.Application;
import android.content.Context;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import android.os.Handler;
import android.os.Looper;
import android.preference.PreferenceManager;
import android.webkit.WebChromeClient;
import android.webkit.WebSettings;
import android.webkit.WebView;
import android.webkit.WebViewClient;
import java.lang.ref.WeakReference;
public class AppSingleton extends Application {
public static Context f;
public static WeakReference g;
public static SharedPreferences h;
public static Editor i;
public static c j;
public static String k;
public static String l;
public static boolean m;
public static boolean n;
public static boolean o;
public static boolean p;
public static boolean q;
public static boolean r;
public static boolean s;
public static int t;
public static boolean u;
public static final Handler v = new Handler(Looper.getMainLooper());
public static e w;
public static void a() {
MainActivity mainActivity = (MainActivity) g.get();
if (mainActivity != null) {
mainActivity.runOnUiThread(new a(mainActivity));
}
}
public static WebView b() {
if (j == null) {
c webView = new WebView(f);
j = webView;
WebSettings settings = webView.getSettings();
settings.setUserAgentString("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36");
settings.setJavaScriptEnabled(true);
settings.setSupportMultipleWindows(true);
settings.setJavaScriptCanOpenWindowsAutomatically(true);
settings.setDomStorageEnabled(true);
settings.setDatabaseEnabled(true);
settings.setMediaPlaybackRequiresUserGesture(false);
settings.setUseWideViewPort(true);
settings.setLoadWithOverviewMode(true);
settings.setSupportZoom(true);
j.setInitialScale(100);
j.addJavascriptInterface(new g(f), "AndBridge");
j.setWebChromeClient(new WebChromeClient());
j.setWebViewClient(new WebViewClient());
if (!u) {
if (n) {
j.loadUrl("https://open.spotify.com/");
} else {
j.loadUrl("https://accounts.spotify.com/login");
}
}
}
return j;
}
public final void onCreate() {
super.onCreate();
f = getApplicationContext();
SharedPreferences defaultSharedPreferences = PreferenceManager.getDefaultSharedPreferences(this);
h = defaultSharedPreferences;
i = defaultSharedPreferences.edit();
m = h.getBoolean("ServiceOn", true);
n = h.getBoolean("LoggedIn", false);
k = h.getString("APlayMode", "disabled");
p = h.getBoolean("CloseNowPlay", false);
o = h.getBoolean("TakeControl", true);
l = h.getString("GuiMode", "csshack");
q = h.getBoolean("AndAuto", true);
r = h.getBoolean("SwipeStop", true);
t = Integer.parseInt(h.getString("AutoSleep", "0"));
s = h.getBoolean("ForceEn", false);
}
}