Skip to content

Commit 4c5cb31

Browse files
authored
Merge branch 'dev' into history_cache_compose
2 parents 0530a6b + 035c394 commit 4c5cb31

File tree

71 files changed

+193
-138
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+193
-138
lines changed

.github/CONTRIBUTING.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,6 @@ The [ktlint](https://github.com/pinterest/ktlint) plugin does the same job as ch
7979

8080
## Communication
8181

82-
* The #newpipe channel on Libera Chat (`ircs://irc.libera.chat:6697/newpipe`) has the core team and other developers in it. [Click here for webchat](https://web.libera.chat/#newpipe)!
83-
* You can also use a Matrix account to join the NewPipe channel at [#newpipe:libera.chat](https://matrix.to/#/#newpipe:libera.chat). Some convenient clients, available both for phone and desktop, are listed at that link.
84-
* You can post your suggestions, changes, ideas etc. on either GitHub or IRC.
82+
* You can use a Matrix account to join the NewPipe channel at [#newpipe:matrix.newpipe-ev.de](https://matrix.to/#/#newpipe:matrix.newpipe-ev.de). Some convenient clients, available both for phone and desktop, are listed at that link.
83+
* Alternatively, the #newpipe channel on Libera Chat (`ircs://irc.libera.chat:6697/newpipe`) can also be joined, as it is bridged to the Matrix room. [Click here for webchat](https://web.libera.chat/#newpipe)!
84+
* You can post your suggestions, changes, ideas etc. on either GitHub or Matrix (including via IRC).

.github/ISSUE_TEMPLATE/config.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ contact_links:
33
- name: ❓ Question
44
url: https://github.com/TeamNewPipe/NewPipe/discussions/new?category=questions
55
about: Ask about anything NewPipe-related
6+
- name: 💬 Matrix
7+
url: https://matrix.to/#/#newpipe:matrix.newpipe-ev.de
8+
about: Chat with us via Matrix for quick Q/A
69
- name: 💬 IRC
710
url: https://web.libera.chat/#newpipe
811
about: Chat with us via IRC for quick Q/A
9-
- name: 💬 Matrix
10-
url: https://matrix.to/#/#newpipe:libera.chat
11-
about: Chat with us via Matrix for quick Q/A

.idea/icon.svg

+21
Loading

app/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ android {
2121
resValue "string", "app_name", "NewPipe"
2222
minSdk 21
2323
targetSdk 33
24-
versionCode 997
25-
versionName "0.27.0"
24+
versionCode 999
25+
versionName "0.27.2"
2626

2727
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
2828

app/proguard-rules.pro

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
-keep class org.schabi.newpipe.extractor.timeago.patterns.** { *; }
88
-keep class org.mozilla.javascript.** { *; }
99
-keep class org.mozilla.classfile.ClassFileWriter
10+
-dontwarn org.mozilla.javascript.JavaToJSONConverters
1011
-dontwarn org.mozilla.javascript.tools.**
1112

1213
## Rules for ExoPlayer

app/src/main/java/org/schabi/newpipe/error/ErrorActivity.java

-22
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import static org.schabi.newpipe.util.Localization.assureCorrectAppLanguage;
44

5-
import android.app.Activity;
65
import android.content.Context;
76
import android.content.Intent;
87
import android.net.Uri;
@@ -13,7 +12,6 @@
1312
import android.view.MenuInflater;
1413
import android.view.MenuItem;
1514

16-
import androidx.annotation.Nullable;
1715
import androidx.appcompat.app.ActionBar;
1816
import androidx.appcompat.app.AlertDialog;
1917
import androidx.appcompat.app.AppCompatActivity;
@@ -22,7 +20,6 @@
2220
import com.grack.nanojson.JsonWriter;
2321

2422
import org.schabi.newpipe.BuildConfig;
25-
import org.schabi.newpipe.MainActivity;
2623
import org.schabi.newpipe.R;
2724
import org.schabi.newpipe.databinding.ActivityErrorBinding;
2825
import org.schabi.newpipe.util.Localization;
@@ -187,25 +184,6 @@ private String formErrorText(final String[] el) {
187184
.collect(Collectors.joining(separator + "\n", separator + "\n", separator));
188185
}
189186

190-
/**
191-
* Get the checked activity.
192-
*
193-
* @param returnActivity the activity to return to
194-
* @return the casted return activity or null
195-
*/
196-
@Nullable
197-
static Class<? extends Activity> getReturnActivity(final Class<?> returnActivity) {
198-
Class<? extends Activity> checkedReturnActivity = null;
199-
if (returnActivity != null) {
200-
if (Activity.class.isAssignableFrom(returnActivity)) {
201-
checkedReturnActivity = returnActivity.asSubclass(Activity.class);
202-
} else {
203-
checkedReturnActivity = MainActivity.class;
204-
}
205-
}
206-
return checkedReturnActivity;
207-
}
208-
209187
private void buildInfo(final ErrorInfo info) {
210188
String text = "";
211189

app/src/main/java/org/schabi/newpipe/error/ReCaptchaActivity.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -190,9 +190,8 @@ private void handleCookiesFromUrl(@Nullable final String url) {
190190
handleCookies(abuseCookie);
191191
} catch (final StringIndexOutOfBoundsException e) {
192192
if (MainActivity.DEBUG) {
193-
e.printStackTrace();
194-
Log.d(TAG, "handleCookiesFromUrl: invalid google abuse starting at "
195-
+ abuseStart + " and ending at " + abuseEnd + " for url " + url);
193+
Log.e(TAG, "handleCookiesFromUrl: invalid google abuse starting at "
194+
+ abuseStart + " and ending at " + abuseEnd + " for url " + url, e);
196195
}
197196
}
198197
}

app/src/main/java/org/schabi/newpipe/player/mediasession/MediaSessionPlayerUi.java

+7
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ public class MediaSessionPlayerUi extends PlayerUi
3838
implements SharedPreferences.OnSharedPreferenceChangeListener {
3939
private static final String TAG = "MediaSessUi";
4040

41+
@Nullable
4142
private MediaSessionCompat mediaSession;
43+
@Nullable
4244
private MediaSessionConnector sessionConnector;
4345

4446
private final String ignoreHardwareMediaButtonsKey;
@@ -198,6 +200,11 @@ private void updateMediaSessionActions() {
198200
return;
199201
}
200202

203+
if (sessionConnector == null) {
204+
// sessionConnector will be null after destroyPlayer is called
205+
return;
206+
}
207+
201208
// only use the fourth and fifth actions (the settings page also shows only the last 2 on
202209
// Android 13+)
203210
final List<NotificationActionData> newNotificationActions = IntStream.of(3, 4)

app/src/main/java/org/schabi/newpipe/settings/DownloadSettingsFragment.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,9 @@ private void showPathInSummary(final String prefKey, @StringRes final int defaul
121121
target.setSummary(new File(URI.create(rawUri)).getPath());
122122
return;
123123
}
124-
125124
rawUri = decodeUrlUtf8(rawUri);
126125

126+
127127
target.setSummary(rawUri);
128128
}
129129

app/src/test/java/org/schabi/newpipe/error/ErrorActivityTest.java

-35
This file was deleted.

doc/README.asm.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ NewPipe এ আপুনি ব্যৱহাৰ কৰা সেৱাৰ অ
106106

107107
## অৱদান
108108

109-
আপোনাৰ ধাৰণা, অনুবাদ, ডিজাইন পৰিবৰ্তন, ক'ড পৰিষ্কাৰ কৰা, বা আনকি ডাঙৰ ক'ড পৰিৱৰ্তন হওক, সহায় সদায় আদৰণীয়। প্ৰতিটো অৱদানৰ লগে লগে এপটো ভাল হৈ পৰে, যিমানেই ডাঙৰ বা সৰু নহওক কিয়! যদি আপুনি জড়িত হ'ব বিচাৰে তেন্তে চাওক আমাৰ [অবদানৰ টোকা সমূহ](.github/CONTRIBUTING.md).<a href="https://hosted.weblate.org/engage/newpipe/"><img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="Translation status" /></a>
109+
আপোনাৰ ধাৰণা, অনুবাদ, ডিজাইন পৰিবৰ্তন, ক'ড পৰিষ্কাৰ কৰা, বা আনকি ডাঙৰ ক'ড পৰিৱৰ্তন হওক, সহায় সদায় আদৰণীয়। প্ৰতিটো অৱদানৰ লগে লগে এপটো ভাল হৈ পৰে, যিমানেই ডাঙৰ বা সৰু নহওক কিয়! যদি আপুনি জড়িত হ'ব বিচাৰে তেন্তে চাওক আমাৰ [অবদানৰ টোকা সমূহ](/.github/CONTRIBUTING.md).<a href="https://hosted.weblate.org/engage/newpipe/"><img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="Translation status" /></a>
110110

111111
## অনুদান
112112

doc/README.de.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ So eine Aktion wird nicht unterstützt und du solltest sie nur in Erwägung zieh
126126
## Beitrag
127127
Egal ob du neue Ideen, Übersetzungen, Designvorschläge, kleine Code-Bereinigungen, oder sogar große Code-Verbesserungen hast, jegliche Unterstützung ist immer gern gesehen.
128128
Die App wird mit _jedem_ Beitrag besser und besser - egal wie viel Arbeit in ihn gesteckt wird!
129-
Wenn du dich einbringen willst, sehe dir die [Beitragshinweise](.github/CONTRIBUTING.md) an.
129+
Wenn du dich einbringen willst, sieh dir die [Beitragshinweise](/.github/CONTRIBUTING.md) an.
130130

131131
<a href="https://hosted.weblate.org/engage/newpipe/de/">
132132
<img src="https://hosted.weblate.org/widgets/newpipe/de/287x66-grey.png" alt="Übersetzt" />

doc/README.fr.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ Entre temps, si vous voulez changer de source pour une raison quelconque (par ex
109109

110110
## Contribuer
111111

112-
Que vous ayez des idées, des traductions, des changements de design, du nettoyage de code, ou encore un changement de code majeur, toute aide est la bienvenue. L'app s'améliore un peu plus à chaque contribution, peu importe qu'elle soit grosse ou petite ! Si vous aimeriez être impliqué, jetez un coup d'oeil à nos [notes pour contribuer](.github/CONTRIBUTING.md).
112+
Que vous ayez des idées, des traductions, des changements de design, du nettoyage de code, ou encore un changement de code majeur, toute aide est la bienvenue. L'app s'améliore un peu plus à chaque contribution, peu importe qu'elle soit grosse ou petite ! Si vous aimeriez être impliqué, jetez un coup d'oeil à nos [notes pour contribuer](/.github/CONTRIBUTING.md).
113113

114114
<a href="https://hosted.weblate.org/engage/newpipe/">
115115
<img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="Translation status" />

doc/README.hi.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ NewPipe पर कई सेवाएँ उपलब्ध हैं। हम
105105
चाहे आप अपने विचार जोड़ना चाहे, या अनुवाद, डिज़ाइन में बदलाव, कोड में सफ़ाई, या कोड में भारी बदलाव, सहायता ज़रूर करें।
106106
जितने योगदान हो, ऐप उतनी ही बेहतर होती जाती है!
107107

108-
अगर आप योगदान करना चाहते हैं, हमारे [योगदान के दिशानिर्देश](.github/CONTRIBUTING.md) देखें।
108+
अगर आप योगदान करना चाहते हैं, हमारे [योगदान के दिशानिर्देश](/.github/CONTRIBUTING.md) देखें।
109109

110110
<a href="https://hosted.weblate.org/engage/newpipe/">
111111
<img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="अनुवाद की स्थिति" />

doc/README.it.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ Nel frattempo, se vuoi cambiare fonte per la stessa ragione (ad es. la funzional
107107

108108
## Contribuire
109109

110-
Se hai idee, traduzioni, cambiamenti di *design*, pulizia di codice, o addirittura grossi cambiamenti di codice, l'aiuto è sempre apprezzato. L'app diventa sempre meglio con ogni contribuzione, non importa quanto grande o piccola essa sia! Se ti piacerebbe essere parte del progetto, vedi le nostre [note di contribuzione](.github/CONTRIBUTING.md).
110+
Se hai idee, traduzioni, cambiamenti di *design*, pulizia di codice, o addirittura grossi cambiamenti di codice, l'aiuto è sempre apprezzato. L'app diventa sempre meglio con ogni contribuzione, non importa quanto grande o piccola essa sia! Se ti piacerebbe essere parte del progetto, vedi le nostre [note di contribuzione](/.github/CONTRIBUTING.md).
111111

112112
<a href="https://hosted.weblate.org/engage/newpipe/">
113113
<img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="Stato traduzione" />

doc/README.pa.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ NewPipe ਤੁਹਾਡੇ ਦੁਆਰਾ ਵਰਤੀ ਜਾ ਰਹੀ ਸੇ
105105
<b>ਨੋਟ: ਜਦੋਂ ਤੁਸੀਂ ਅਧਿਕਾਰਤ ਐਪ ਵਿੱਚ ਇੱਕ ਡੇਟਾਬੇਸ ਨੂੰ ਆਯਾਤ ਕਰ ਰਹੇ ਹੋ, ਤਾਂ ਹਮੇਸ਼ਾਂ ਯਕੀਨੀ ਬਣਾਓ ਕਿ ਇਹ ਉਹੀ ਹੈ ਜੋ ਤੁਸੀਂ ਅਧਿਕਾਰਤ ਐਪ ਤੋਂ ਨਿਰਯਾਤ ਕੀਤਾ ਹੈ। ਜੇਕਰ ਤੁਸੀਂ ਅਧਿਕਾਰਤ ਐਪ ਤੋਂ ਇਲਾਵਾ ਕਿਸੇ ਏਪੀਕੇ ਤੋਂ ਨਿਰਯਾਤ ਕੀਤੇ ਡੇਟਾਬੇਸ ਨੂੰ ਆਯਾਤ ਕਰਦੇ ਹੋ, ਤਾਂ ਇਹ ਚੀਜ਼ਾਂ ਨੂੰ ਤੋੜ ਸਕਦਾ ਹੈ। ਅਜਿਹੀ ਕਾਰਵਾਈ ਅਸਮਰਥਿਤ ਹੈ, ਅਤੇ ਤੁਹਾਨੂੰ ਅਜਿਹਾ ਉਦੋਂ ਹੀ ਕਰਨਾ ਚਾਹੀਦਾ ਹੈ ਜਦੋਂ ਤੁਹਾਨੂੰ ਪੂਰੀ ਤਰ੍ਹਾਂ ਯਕੀਨ ਹੋਵੇ ਕਿ ਤੁਸੀਂ ਜਾਣਦੇ ਹੋ ਕਿ ਤੁਸੀਂ ਕੀ ਕਰ ਰਹੇ ਹੋ।</b>
106106

107107
## ਯੋਗਦਾਨ
108-
ਭਾਵੇਂ ਤੁਹਾਡੇ ਕੋਲ ਵਿਚਾਰ, ਅਨੁਵਾਦ, ਡਿਜ਼ਾਈਨ ਤਬਦੀਲੀਆਂ, ਕੋਡ ਦੀ ਸਫਾਈ, ਜਾਂ ਇੱਥੋਂ ਤੱਕ ਕਿ ਵੱਡੀਆਂ ਕੋਡ ਤਬਦੀਲੀਆਂ ਹੋਣ, ਮਦਦ ਦਾ ਹਮੇਸ਼ਾ ਸਵਾਗਤ ਹੈ। ਐਪ ਹਰੇਕ ਯੋਗਦਾਨ ਦੇ ਨਾਲ ਬਿਹਤਰ ਅਤੇ ਬਿਹਤਰ ਹੋ ਜਾਂਦੀ ਹੈ, ਚਾਹੇ ਉਹ ਕਿੰਨਾ ਵੱਡਾ ਜਾਂ ਛੋਟਾ ਹੋਵੇ! ਜੇਕਰ ਤੁਸੀਂ ਸ਼ਾਮਲ ਹੋਣਾ ਚਾਹੁੰਦੇ ਹੋ, ਤਾਂ ਸਾਡੀ ਜਾਂਚ ਕਰੋ [contribution notes](.github/CONTRIBUTING.md).
108+
ਭਾਵੇਂ ਤੁਹਾਡੇ ਕੋਲ ਵਿਚਾਰ, ਅਨੁਵਾਦ, ਡਿਜ਼ਾਈਨ ਤਬਦੀਲੀਆਂ, ਕੋਡ ਦੀ ਸਫਾਈ, ਜਾਂ ਇੱਥੋਂ ਤੱਕ ਕਿ ਵੱਡੀਆਂ ਕੋਡ ਤਬਦੀਲੀਆਂ ਹੋਣ, ਮਦਦ ਦਾ ਹਮੇਸ਼ਾ ਸਵਾਗਤ ਹੈ। ਐਪ ਹਰੇਕ ਯੋਗਦਾਨ ਦੇ ਨਾਲ ਬਿਹਤਰ ਅਤੇ ਬਿਹਤਰ ਹੋ ਜਾਂਦੀ ਹੈ, ਚਾਹੇ ਉਹ ਕਿੰਨਾ ਵੱਡਾ ਜਾਂ ਛੋਟਾ ਹੋਵੇ! ਜੇਕਰ ਤੁਸੀਂ ਸ਼ਾਮਲ ਹੋਣਾ ਚਾਹੁੰਦੇ ਹੋ, ਤਾਂ ਸਾਡੀ ਜਾਂਚ ਕਰੋ [contribution notes](/.github/CONTRIBUTING.md).
109109

110110
<a href="https://hosted.weblate.org/engage/newpipe/">
111111
<img src="https://hosted.weblate.org/widgets/newpipe/-/287x66-grey.png" alt="Translation status" />

0 commit comments

Comments
 (0)