mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-20 16:57:32 +01:00
feat: Globals
class for proxying getAppContext
This commit is contained in:
parent
241899197d
commit
e98bcd2216
18
app/src/main/java/app.revanced/integrations/Globals.java
Normal file
18
app/src/main/java/app.revanced/integrations/Globals.java
Normal file
@ -0,0 +1,18 @@
|
||||
package app.revanced.integrations;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
|
||||
public class Globals {
|
||||
public static Context context;
|
||||
|
||||
public static Context getAppContext() {
|
||||
|
||||
if (context != null) {
|
||||
return context;
|
||||
}
|
||||
Log.e("Globals", "Context is null!");
|
||||
return null;
|
||||
}
|
||||
}
|
@ -2,13 +2,8 @@ package com.google.android.apps.youtube.app;
|
||||
|
||||
import android.app.Application;
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
|
||||
public class YouTubeTikTokRoot_Application extends Application {
|
||||
protected void onCreate(final Bundle bundle) {
|
||||
super.onCreate();
|
||||
}
|
||||
|
||||
public static Context getAppContext() {
|
||||
return null;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user