chore: Separate extensions by app (#3905)

This commit is contained in:
oSumAtrIX
2024-12-05 12:12:48 +01:00
committed by GitHub
parent 69ec47cbef
commit cc40246e60
314 changed files with 371 additions and 148 deletions

View File

@ -0,0 +1,3 @@
dependencies {
compileOnly(project(":extensions:reddit:stub"))
}

View File

@ -0,0 +1 @@
<manifest/>

View File

@ -0,0 +1,23 @@
package app.revanced.extension.patches;
import com.reddit.domain.model.ILink;
import java.util.ArrayList;
import java.util.List;
public final class FilterPromotedLinksPatch {
/**
* Filters list from promoted links.
**/
public static List<?> filterChildren(final Iterable<?> links) {
final List<Object> filteredList = new ArrayList<>();
for (Object item : links) {
if (item instanceof ILink && ((ILink) item).getPromoted()) continue;
filteredList.add(item);
}
return filteredList;
}
}

View File

@ -0,0 +1,17 @@
plugins {
id(libs.plugins.android.library.get().pluginId)
}
android {
namespace = "app.revanced.extension"
compileSdk = 33
defaultConfig {
minSdk = 24
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
}

View File

@ -0,0 +1 @@
<manifest/>

View File

@ -0,0 +1,7 @@
package com.reddit.domain.model;
public class ILink {
public boolean getPromoted() {
throw new UnsupportedOperationException("Stub");
}
}