diff --git a/app/src/main/java/app/revanced/integrations/patches/ReturnYouTubeDislikesPatch.java b/app/src/main/java/app/revanced/integrations/patches/ReturnYouTubeDislikesPatch.java index cfdfd71bf8..6a4ebb83de 100644 --- a/app/src/main/java/app/revanced/integrations/patches/ReturnYouTubeDislikesPatch.java +++ b/app/src/main/java/app/revanced/integrations/patches/ReturnYouTubeDislikesPatch.java @@ -2,7 +2,7 @@ import java.util.concurrent.atomic.AtomicReference; -import app.revanced.integrations.ryd.ReturnYouTubeDislikes; +import app.revanced.integrations.returnyoutubedislike.ReturnYouTubeDislike; /** * Used by app.revanced.patches.youtube.layout.returnyoutubedislikes.patch.RYDPatch @@ -13,14 +13,14 @@ public class ReturnYouTubeDislikesPatch { * Called when the video id changes */ public static void newVideoLoaded(String videoId) { - ReturnYouTubeDislikes.newVideoLoaded(videoId); + ReturnYouTubeDislike.newVideoLoaded(videoId); } /** * Called when a litho text component is created */ public static void onComponentCreated(Object conversionContext, AtomicReference textRef) { - ReturnYouTubeDislikes.onComponentCreated(conversionContext, textRef); + ReturnYouTubeDislike.onComponentCreated(conversionContext, textRef); } /** @@ -28,6 +28,6 @@ public static void onComponentCreated(Object conversionContext, AtomicReference< * @param vote -1 (dislike), 0 (none) or 1 (like) */ public static void sendVote(int vote) { - ReturnYouTubeDislikes.sendVote(vote); + ReturnYouTubeDislike.sendVote(vote); } } diff --git a/app/src/main/java/app/revanced/integrations/ryd/Registration.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/Registration.java similarity index 93% rename from app/src/main/java/app/revanced/integrations/ryd/Registration.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/Registration.java index 9573ae184a..7ad23176a9 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/Registration.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/Registration.java @@ -1,4 +1,4 @@ -package app.revanced.integrations.ryd; +package app.revanced.integrations.returnyoutubedislike; import android.util.Base64; @@ -8,7 +8,7 @@ import app.revanced.integrations.settings.SettingsEnum; import app.revanced.integrations.utils.LogHelper; -import app.revanced.integrations.ryd.requests.RYDRequester; +import app.revanced.integrations.returnyoutubedislike.requests.ReturnYouTubeDislikeApi; public class Registration { @@ -58,7 +58,7 @@ public static String solvePuzzle(String challenge, int difficulty) { private String register() { String userId = randomString(36); LogHelper.debug(Registration.class, "Trying to register the following userId: " + userId); - return RYDRequester.register(userId, this); + return ReturnYouTubeDislikeApi.register(userId, this); } private String randomString(int len) { diff --git a/app/src/main/java/app/revanced/integrations/ryd/ReturnYouTubeDislikes.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/ReturnYouTubeDislike.java similarity index 73% rename from app/src/main/java/app/revanced/integrations/ryd/ReturnYouTubeDislikes.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/ReturnYouTubeDislike.java index 0c6e6c9e23..44fef8c014 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/ReturnYouTubeDislikes.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/ReturnYouTubeDislike.java @@ -1,4 +1,4 @@ -package app.revanced.integrations.ryd; +package app.revanced.integrations.returnyoutubedislike; import static app.revanced.integrations.videoplayer.VideoInformation.currentVideoId; import static app.revanced.integrations.videoplayer.VideoInformation.dislikeCount; @@ -12,13 +12,13 @@ import java.util.Objects; import java.util.concurrent.atomic.AtomicReference; -import app.revanced.integrations.ryd.requests.RYDRequester; +import app.revanced.integrations.returnyoutubedislike.requests.ReturnYouTubeDislikeApi; import app.revanced.integrations.settings.SettingsEnum; import app.revanced.integrations.utils.LogHelper; import app.revanced.integrations.utils.ReVancedUtils; import app.revanced.integrations.utils.SharedPrefHelper; -public class ReturnYouTubeDislikes { +public class ReturnYouTubeDislike { private static boolean isEnabled; private static Thread _dislikeFetchThread = null; private static Thread _votingThread = null; @@ -35,7 +35,7 @@ public class ReturnYouTubeDislikes { } Locale locale = context.getResources().getConfiguration().locale; - LogHelper.debug(ReturnYouTubeDislikes.class, "locale - " + locale); + LogHelper.debug(ReturnYouTubeDislike.class, "locale - " + locale); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { compactNumberFormatter = CompactDecimalFormat.getInstance( locale, @@ -55,21 +55,21 @@ public static void onEnabledChange(boolean enabled) { } public static void newVideoLoaded(String videoId) { - LogHelper.debug(ReturnYouTubeDislikes.class, "newVideoLoaded - " + videoId); + LogHelper.debug(ReturnYouTubeDislike.class, "newVideoLoaded - " + videoId); dislikeCount = null; if (!isEnabled) return; try { if (_dislikeFetchThread != null && _dislikeFetchThread.getState() != Thread.State.TERMINATED) { - LogHelper.debug(ReturnYouTubeDislikes.class, "Interrupting the thread. Current state " + _dislikeFetchThread.getState()); + LogHelper.debug(ReturnYouTubeDislike.class, "Interrupting the thread. Current state " + _dislikeFetchThread.getState()); _dislikeFetchThread.interrupt(); } } catch (Exception ex) { - LogHelper.printException(ReturnYouTubeDislikes.class, "Error in the dislike fetch thread", ex); + LogHelper.printException(ReturnYouTubeDislike.class, "Error in the dislike fetch thread", ex); } - _dislikeFetchThread = new Thread(() -> RYDRequester.fetchDislikes(videoId)); + _dislikeFetchThread = new Thread(() -> ReturnYouTubeDislikeApi.fetchDislikes(videoId)); _dislikeFetchThread.start(); } @@ -80,7 +80,7 @@ public static void onComponentCreated(Object conversionContext, AtomicReference< // Contains a pathBuilder string, used to distinguish from other litho components if (!conversionContext.toString().contains("dislike_button")) return; - LogHelper.debug(ReturnYouTubeDislikes.class, "dislike button was created"); + LogHelper.debug(ReturnYouTubeDislike.class, "dislike button was created"); // Have to block the current thread until fetching is done // There's no known way to edit the text after creation yet @@ -90,7 +90,7 @@ public static void onComponentCreated(Object conversionContext, AtomicReference< updateDislikeText(textRef, formatDislikes(dislikeCount)); } } catch (Exception ex) { - LogHelper.printException(ReturnYouTubeDislikes.class, "Error while trying to set dislikes text", ex); + LogHelper.printException(ReturnYouTubeDislike.class, "Error while trying to set dislikes text", ex); } } @@ -101,22 +101,22 @@ public static void sendVote(int vote) { if (SharedPrefHelper.getBoolean(Objects.requireNonNull(context), SharedPrefHelper.SharedPrefNames.YOUTUBE, "user_signed_out", true)) return; - LogHelper.debug(ReturnYouTubeDislikes.class, "sending vote - " + vote + " for video " + currentVideoId); + LogHelper.debug(ReturnYouTubeDislike.class, "sending vote - " + vote + " for video " + currentVideoId); try { if (_votingThread != null && _votingThread.getState() != Thread.State.TERMINATED) { - LogHelper.debug(ReturnYouTubeDislikes.class, "Interrupting the thread. Current state " + _votingThread.getState()); + LogHelper.debug(ReturnYouTubeDislike.class, "Interrupting the thread. Current state " + _votingThread.getState()); _votingThread.interrupt(); } } catch (Exception ex) { - LogHelper.printException(ReturnYouTubeDislikes.class, "Error in the voting thread", ex); + LogHelper.printException(ReturnYouTubeDislike.class, "Error in the voting thread", ex); } _votingThread = new Thread(() -> { try { boolean result = voting.sendVote(currentVideoId, vote); - LogHelper.debug(ReturnYouTubeDislikes.class, "sendVote status " + result); + LogHelper.debug(ReturnYouTubeDislike.class, "sendVote status " + result); } catch (Exception ex) { - LogHelper.printException(ReturnYouTubeDislikes.class, "Failed to send vote", ex); + LogHelper.printException(ReturnYouTubeDislike.class, "Failed to send vote", ex); } }); _votingThread.start(); @@ -139,10 +139,10 @@ private static void updateDislikeText(AtomicReference textRef, String te private static String formatDislikes(int dislikes) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N && compactNumberFormatter != null) { final String formatted = compactNumberFormatter.format(dislikes); - LogHelper.debug(ReturnYouTubeDislikes.class, "Formatting dislikes - " + dislikes + " - " + formatted); + LogHelper.debug(ReturnYouTubeDislike.class, "Formatting dislikes - " + dislikes + " - " + formatted); return formatted; } - LogHelper.debug(ReturnYouTubeDislikes.class, "Couldn't format dislikes, using the unformatted count - " + dislikes); + LogHelper.debug(ReturnYouTubeDislike.class, "Couldn't format dislikes, using the unformatted count - " + dislikes); return String.valueOf(dislikes); } } diff --git a/app/src/main/java/app/revanced/integrations/ryd/Voting.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/Voting.java similarity index 68% rename from app/src/main/java/app/revanced/integrations/ryd/Voting.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/Voting.java index 834c5c9e43..cf82c317d8 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/Voting.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/Voting.java @@ -1,7 +1,7 @@ -package app.revanced.integrations.ryd; +package app.revanced.integrations.returnyoutubedislike; import app.revanced.integrations.utils.LogHelper; -import app.revanced.integrations.ryd.requests.RYDRequester; +import app.revanced.integrations.returnyoutubedislike.requests.ReturnYouTubeDislikeApi; public class Voting { private Registration registration; @@ -13,6 +13,6 @@ public Voting(Registration registration) { public boolean sendVote(String videoId, int vote) { String userId = registration.getUserId(); LogHelper.debug(Voting.class, "Trying to vote the following video: " + videoId + " with vote " + vote + " and userId: " + userId); - return RYDRequester.sendVote(videoId, userId, vote); + return ReturnYouTubeDislikeApi.sendVote(videoId, userId, vote); } } diff --git a/app/src/main/java/app/revanced/integrations/ryd/dialog/Dialogs.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/dialog/Dialogs.java similarity index 97% rename from app/src/main/java/app/revanced/integrations/ryd/dialog/Dialogs.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/dialog/Dialogs.java index 68417164a9..ae5ec16aa5 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/dialog/Dialogs.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/dialog/Dialogs.java @@ -1,4 +1,4 @@ -package app.revanced.integrations.ryd.dialog; +package app.revanced.integrations.returnyoutubedislike.dialog; import static app.revanced.integrations.sponsorblock.StringRef.str; diff --git a/app/src/main/java/app/revanced/integrations/ryd/requests/RYDRequester.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeApi.java similarity index 66% rename from app/src/main/java/app/revanced/integrations/ryd/requests/RYDRequester.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeApi.java index 24eade335e..62b410ee9b 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/requests/RYDRequester.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeApi.java @@ -1,4 +1,4 @@ -package app.revanced.integrations.ryd.requests; +package app.revanced.integrations.returnyoutubedislike.requests; import static app.revanced.integrations.videoplayer.VideoInformation.dislikeCount; import static app.revanced.integrations.whitelist.requests.Requester.parseJson; @@ -12,65 +12,65 @@ import java.nio.charset.StandardCharsets; import app.revanced.integrations.utils.LogHelper; -import app.revanced.integrations.ryd.Registration; +import app.revanced.integrations.returnyoutubedislike.Registration; import app.revanced.integrations.whitelist.requests.Requester; import app.revanced.integrations.whitelist.requests.Route; -public class RYDRequester { +public class ReturnYouTubeDislikeApi { private static final String RYD_API_URL = "https://returnyoutubedislikeapi.com/"; - private RYDRequester() { + private ReturnYouTubeDislikeApi() { } public static void fetchDislikes(String videoId) { try { - LogHelper.debug(RYDRequester.class, "Fetching dislikes for " + videoId); - HttpURLConnection connection = getConnectionFromRoute(RYDRoutes.GET_DISLIKES, videoId); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Fetching dislikes for " + videoId); + HttpURLConnection connection = getConnectionFromRoute(ReturnYouTubeDislikeRoutes.GET_DISLIKES, videoId); connection.setConnectTimeout(5 * 1000); if (connection.getResponseCode() == 200) { JSONObject json = getJSONObject(connection); dislikeCount = json.getInt("dislikes"); - LogHelper.debug(RYDRequester.class, "dislikes fetched - " + dislikeCount); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "dislikes fetched - " + dislikeCount); } else { - LogHelper.debug(RYDRequester.class, "dislikes fetch response was " + connection.getResponseCode()); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "dislikes fetch response was " + connection.getResponseCode()); } connection.disconnect(); } catch (Exception ex) { dislikeCount = null; - LogHelper.printException(RYDRequester.class, "Failed to fetch dislikes", ex); + LogHelper.printException(ReturnYouTubeDislikeApi.class, "Failed to fetch dislikes", ex); } } public static String register(String userId, Registration registration) { try { - HttpURLConnection connection = getConnectionFromRoute(RYDRoutes.GET_REGISTRATION, userId); + HttpURLConnection connection = getConnectionFromRoute(ReturnYouTubeDislikeRoutes.GET_REGISTRATION, userId); connection.setConnectTimeout(5 * 1000); if (connection.getResponseCode() == 200) { JSONObject json = getJSONObject(connection); String challenge = json.getString("challenge"); int difficulty = json.getInt("difficulty"); - LogHelper.debug(RYDRequester.class, "Registration challenge - " + challenge + " with difficulty of " + difficulty); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration challenge - " + challenge + " with difficulty of " + difficulty); // Solve the puzzle String solution = Registration.solvePuzzle(challenge, difficulty); - LogHelper.debug(RYDRequester.class, "Registration confirmation solution is " + solution); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration confirmation solution is " + solution); return confirmRegistration(userId, solution, registration); } else { - LogHelper.debug(RYDRequester.class, "Registration response was " + connection.getResponseCode()); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration response was " + connection.getResponseCode()); } connection.disconnect(); } catch (Exception ex) { - LogHelper.printException(RYDRequester.class, "Failed to register userId", ex); + LogHelper.printException(ReturnYouTubeDislikeApi.class, "Failed to register userId", ex); } return null; } private static String confirmRegistration(String userId, String solution, Registration registration) { try { - LogHelper.debug(RYDRequester.class, "Trying to confirm registration for the following userId: " + userId + " with solution: " + solution); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Trying to confirm registration for the following userId: " + userId + " with solution: " + solution); - HttpURLConnection connection = getConnectionFromRoute(RYDRoutes.CONFIRM_REGISTRATION, userId); + HttpURLConnection connection = getConnectionFromRoute(ReturnYouTubeDislikeRoutes.CONFIRM_REGISTRATION, userId); applyCommonRequestSettings(connection); String jsonInputString = "{\"solution\": \"" + solution + "\"}"; @@ -80,20 +80,20 @@ private static String confirmRegistration(String userId, String solution, Regist } if (connection.getResponseCode() == 200) { String result = parseJson(connection); - LogHelper.debug(RYDRequester.class, "Registration confirmation result was " + result); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration confirmation result was " + result); if (result.equalsIgnoreCase("true")) { registration.saveUserId(userId); - LogHelper.debug(RYDRequester.class, "Registration was successful for user " + userId); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration was successful for user " + userId); return userId; } } else { - LogHelper.debug(RYDRequester.class, "Registration confirmation response was " + connection.getResponseCode()); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Registration confirmation response was " + connection.getResponseCode()); } connection.disconnect(); } catch (Exception ex) { - LogHelper.printException(RYDRequester.class, "Failed to confirm registration", ex); + LogHelper.printException(ReturnYouTubeDislikeApi.class, "Failed to confirm registration", ex); } return null; @@ -101,7 +101,7 @@ private static String confirmRegistration(String userId, String solution, Regist public static boolean sendVote(String videoId, String userId, int vote) { try { - HttpURLConnection connection = getConnectionFromRoute(RYDRoutes.SEND_VOTE); + HttpURLConnection connection = getConnectionFromRoute(ReturnYouTubeDislikeRoutes.SEND_VOTE); applyCommonRequestSettings(connection); String voteJsonString = "{\"userId\": \"" + userId + "\", \"videoId\": \"" + videoId + "\", \"value\": \"" + vote + "\"}"; @@ -114,27 +114,27 @@ public static boolean sendVote(String videoId, String userId, int vote) { JSONObject json = getJSONObject(connection); String challenge = json.getString("challenge"); int difficulty = json.getInt("difficulty"); - LogHelper.debug(RYDRequester.class, "Vote challenge - " + challenge + " with difficulty of " + difficulty); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote challenge - " + challenge + " with difficulty of " + difficulty); // Solve the puzzle String solution = Registration.solvePuzzle(challenge, difficulty); - LogHelper.debug(RYDRequester.class, "Vote confirmation solution is " + solution); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote confirmation solution is " + solution); // Confirm vote return confirmVote(videoId, userId, solution); } else { - LogHelper.debug(RYDRequester.class, "Vote response was " + connection.getResponseCode()); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote response was " + connection.getResponseCode()); } connection.disconnect(); } catch (Exception ex) { - LogHelper.printException(RYDRequester.class, "Failed to send vote", ex); + LogHelper.printException(ReturnYouTubeDislikeApi.class, "Failed to send vote", ex); } return false; } private static boolean confirmVote(String videoId, String userId, String solution) { try { - HttpURLConnection connection = getConnectionFromRoute(RYDRoutes.CONFIRM_VOTE); + HttpURLConnection connection = getConnectionFromRoute(ReturnYouTubeDislikeRoutes.CONFIRM_VOTE); applyCommonRequestSettings(connection); String jsonInputString = "{\"userId\": \"" + userId + "\", \"videoId\": \"" + videoId + "\", \"solution\": \"" + solution + "\"}"; @@ -144,20 +144,20 @@ private static boolean confirmVote(String videoId, String userId, String solutio } if (connection.getResponseCode() == 200) { String result = parseJson(connection); - LogHelper.debug(RYDRequester.class, "Vote confirmation result was " + result); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote confirmation result was " + result); if (result.equalsIgnoreCase("true")) { - LogHelper.debug(RYDRequester.class, "Vote was successful for user " + userId); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote was successful for user " + userId); return true; } } else { - LogHelper.debug(RYDRequester.class, "Vote confirmation response was " + connection.getResponseCode()); + LogHelper.debug(ReturnYouTubeDislikeApi.class, "Vote confirmation response was " + connection.getResponseCode()); } connection.disconnect(); } catch (Exception ex) { - LogHelper.printException(RYDRequester.class, "Failed to confirm vote", ex); + LogHelper.printException(ReturnYouTubeDislikeApi.class, "Failed to confirm vote", ex); } return false; } diff --git a/app/src/main/java/app/revanced/integrations/ryd/requests/RYDRoutes.java b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeRoutes.java similarity index 82% rename from app/src/main/java/app/revanced/integrations/ryd/requests/RYDRoutes.java rename to app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeRoutes.java index 16dec54cb6..64136f8efb 100644 --- a/app/src/main/java/app/revanced/integrations/ryd/requests/RYDRoutes.java +++ b/app/src/main/java/app/revanced/integrations/returnyoutubedislike/requests/ReturnYouTubeDislikeRoutes.java @@ -1,17 +1,17 @@ -package app.revanced.integrations.ryd.requests; +package app.revanced.integrations.returnyoutubedislike.requests; import static app.revanced.integrations.whitelist.requests.Route.Method.GET; import static app.revanced.integrations.whitelist.requests.Route.Method.POST; import app.revanced.integrations.whitelist.requests.Route; -public class RYDRoutes { +public class ReturnYouTubeDislikeRoutes { public static final Route SEND_VOTE = new Route(POST, "interact/vote"); public static final Route CONFIRM_VOTE = new Route(POST, "interact/confirmVote"); public static final Route GET_DISLIKES = new Route(GET, "votes?videoId={video_id}"); public static final Route GET_REGISTRATION = new Route(GET, "puzzle/registration?userId={user_id}"); public static final Route CONFIRM_REGISTRATION = new Route(POST, "puzzle/registration?userId={user_id}"); - private RYDRoutes() { + private ReturnYouTubeDislikeRoutes() { } } \ No newline at end of file diff --git a/app/src/main/java/app/revanced/integrations/settingsmenu/ReVancedSettingActivity.java b/app/src/main/java/app/revanced/integrations/settingsmenu/ReVancedSettingActivity.java index 43b8ee339f..14ff52d354 100644 --- a/app/src/main/java/app/revanced/integrations/settingsmenu/ReVancedSettingActivity.java +++ b/app/src/main/java/app/revanced/integrations/settingsmenu/ReVancedSettingActivity.java @@ -37,7 +37,7 @@ protected void onCreate(Bundle bundle) { getFragmentManager().beginTransaction().replace(getIdentifier("xsettings_fragments", "id"), new SponsorBlockSettingsFragment()).commit(); } else if (dataString.equalsIgnoreCase("ryd_settings")) { trySetTitle(getIdentifier("revanced_ryd_settings_title", "string")); - getFragmentManager().beginTransaction().replace(getIdentifier("xsettings_fragments", "id"), new RYDSettingsFragment()).commit(); + getFragmentManager().beginTransaction().replace(getIdentifier("xsettings_fragments", "id"), new ReturnYouTubeDislikeSettingsFragment()).commit(); } else { trySetTitle(getIdentifier("revanced_settings", "string")); getFragmentManager().beginTransaction().replace(getIdentifier("xsettings_fragments", "id"), new ReVancedSettingsFragment()).commit(); diff --git a/app/src/main/java/app/revanced/integrations/settingsmenu/RYDSettingsFragment.java b/app/src/main/java/app/revanced/integrations/settingsmenu/ReturnYouTubeDislikeSettingsFragment.java similarity index 94% rename from app/src/main/java/app/revanced/integrations/settingsmenu/RYDSettingsFragment.java rename to app/src/main/java/app/revanced/integrations/settingsmenu/ReturnYouTubeDislikeSettingsFragment.java index 78d08de468..097e2e1f1d 100644 --- a/app/src/main/java/app/revanced/integrations/settingsmenu/RYDSettingsFragment.java +++ b/app/src/main/java/app/revanced/integrations/settingsmenu/ReturnYouTubeDislikeSettingsFragment.java @@ -13,11 +13,11 @@ import android.preference.PreferenceScreen; import android.preference.SwitchPreference; -import app.revanced.integrations.ryd.ReturnYouTubeDislikes; +import app.revanced.integrations.returnyoutubedislike.ReturnYouTubeDislike; import app.revanced.integrations.settings.SettingsEnum; import app.revanced.integrations.utils.SharedPrefHelper; -public class RYDSettingsFragment extends PreferenceFragment { +public class ReturnYouTubeDislikeSettingsFragment extends PreferenceFragment { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); @@ -39,7 +39,7 @@ public void onCreate(Bundle savedInstanceState) { preference.setSummary(str("revanced_ryd_summary")); preference.setOnPreferenceChangeListener((pref, newValue) -> { final boolean value = (Boolean) newValue; - ReturnYouTubeDislikes.onEnabledChange(value); + ReturnYouTubeDislike.onEnabledChange(value); return true; }); }