1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2024-06-28 16:13:20 +00:00
Commit Graph

472 Commits

Author SHA1 Message Date
litetex
82de35d724 Use view binding inside `PreferenceViewHolder` 2022-01-24 21:08:52 +01:00
litetex
f55e8ea3aa Use ViewBinding 2022-01-24 21:08:52 +01:00
litetex
7067ebdd12 Fixed imports 2022-01-24 21:08:51 +01:00
litetex
03bb2123f2 Removed breadcrumbs customization 2022-01-24 21:08:51 +01:00
litetex
e2f449f0c8 Code improvements
* Renamed methods so that they are more understandable
* Removed ``SearchIndexItem``
2022-01-24 21:08:50 +01:00
litetex
b16e972710 Improved doc 2022-01-24 21:08:50 +01:00
litetex
37cd71328c Moved `FuzzyScore` to original Apache package 2022-01-24 21:08:49 +01:00
litetex
9b2c86a37b Improved documentation 2022-01-24 21:08:48 +01:00
litetex
ce4dd33eab Fixed problems with Android's lifecycle (restore) 2022-01-24 21:08:48 +01:00
litetex
c5a06243a6 Fixed variable name 2022-01-24 21:08:47 +01:00
litetex
bebd2b449c Removed unused import 2022-01-24 21:08:46 +01:00
litetex
658168eb8d Fixed some sonar warnings 2022-01-24 21:08:45 +01:00
litetex
6b23df0659 Made debug settings searchable (debug only)
* Consolidated main-setttings into a single file
* Debug settings are only enabled in the DEBUG build
* Moved LeakCanary (debug) specific stuff into a small class that's only shipped with the debug build
* Other minor fixes
2022-01-24 21:08:45 +01:00
litetex
d59314801c Code rework 2022-01-24 21:08:44 +01:00
litetex
0f45c69388 Code cleanup + indexing improvements
* Removed unused method
* Only index all settings once -> Saves performance
* Fixed some SonarLint reported problems
2022-01-24 21:08:44 +01:00
litetex
52542e04e8 Added fuzzy searching + Some minor code refactoring 2022-01-24 21:08:43 +01:00
litetex
7fc0a3841a Fine tuning 2022-01-24 21:08:42 +01:00
litetex
22db4175f3 Moved reset-reCAPTCHA-cookie to cache tab and made it read-only
so that the search works as expected
2022-01-24 21:08:42 +01:00
litetex
07fb319e88 Applied code changes for preference search framework 2022-01-24 21:08:41 +01:00
litetex
12a78a826d Added preference search "framework" 2022-01-24 21:08:40 +01:00
litetex
4a061f20ed Code cleanup 2022-01-24 21:08:39 +01:00
litetex
683d9816cb Removed dead code 2022-01-24 21:08:38 +01:00
litetex
6dcde96f85 Fixed some Sonarlint warnings 2022-01-05 15:31:55 +01:00
Stypox
cd95ec4e12
Merge branch 'dev' into pr2335 2021-12-31 19:20:18 +01:00
TobiGr
37b8a9375f Small improvements to code quality and readability
Add annotations to methods and parameters.
Replace Jetbrains' @NotNull with Androidx' @NonNull annotatiation.
Make class variables static if possible.
Use constants for some Strings.
Simplify if conditions.
2021-12-21 20:55:41 +01:00
TobiGr
d71af9a625 Introduce constants for some Strings that indicate no data in Tab class 2021-12-21 20:53:17 +01:00
litetex
b21d231e3a
Merge pull request #7452 from litetex/show-alert-when-file-manager-not-found
Show an alert-dialog when no appropriate file-manager was found
2021-12-14 20:01:02 +01:00
TobiGr
19fd7bc37e Reduce power consumption
Only schedule the chek for new streams if the user enaled the check. Cancel the worker when the user disables the notifications.
2021-12-10 23:52:37 +01:00
TobiGr
3ade2bb6ec Merge remote-tracking branch 'origin/dev' into notifications 2021-12-07 17:29:37 +01:00
Stypox
81f740d409
Replace ErrorActivity with ErrorUtil 2021-12-04 10:36:36 +01:00
litetex
b2323859e5 Refactoring + deduplicated code 2021-11-28 14:07:45 +01:00
litetex
68e7fcf8ee Fixed typos 2021-11-27 23:39:17 +01:00
litetex
f78983b16b Show an alert/dialog when no appropriate file-manager was found 2021-11-27 15:52:54 +01:00
litetex
272be36dd9 Removed `e.printStacktrace` and used an proper logger 2021-11-05 18:04:49 +01:00
litetex
7b4e5dd107 Reworked player-notfication
* Fixed ``release`` ``main_settings.xml``
* Renamed "Notification" to "Player-Notification" (also reset all translations)
2021-11-05 14:10:53 +01:00
litetex
0f4b6d7d9f Improved code readablity 2021-11-02 23:22:52 +01:00
TobiGr
1130aba7ca Merge remote-tracking branch 'origin/dev' into notifications-1 2021-11-02 07:56:09 +01:00
litetex
e5fd24b0d1 Make naming great again
When we build APKs in PRs it's also a GITHUB_APK...
2021-10-26 20:47:14 +02:00
litetex
467bd21de2 Cleanup up some code 2021-10-26 20:47:13 +02:00
vhouriet
5c9705d94e Change check for updates button to trigger a version check 2021-10-26 20:47:12 +02:00
vhouriet
85fb5827aa Add Check for updates button 2021-10-26 20:47:11 +02:00
TobiGr
77aaa15082 Fix toggling the system's settings for app notification
Do not open the setting for a specific notification channel (Settings.ACTION_CHANNEL_NOTIFICATION_SETTINGS), but the settings for all notifications by the app (Settings.ACTION_APP_NOTIFICATION_SETTINGS)
2021-10-25 13:59:55 +02:00
TobiGr
80bf47493e Fix check wether the app's notifications are disabled via system settings
Add comments
Rename a few methods
2021-10-22 21:24:43 +02:00
TacoTheDank
b6b19b474e Update RecyclerView & Groupie 2021-10-19 17:31:59 -04:00
TobiGr
7d4c7718aa comments & rename 2021-10-18 13:11:50 +02:00
TobiGr
64a7978c7f Rename NotificationMode.ENABLED_DEFAULT to NotificationMode.ENABLED 2021-10-15 19:59:06 +02:00
TobiGr
cea14c9d0d Merge remote-tracking branch 'origin/dev' into notifications-1 2021-10-11 16:37:49 +02:00
Tobi
ce592f4baf
Merge pull request #6980 from bravenewpipe/check-for-update-after-toggle-and-restart
resets the expire date for checking for updates
2021-10-02 09:07:05 +02:00
Tobi
2b3edcf2d1
Add a comment 2021-10-02 08:53:03 +02:00
Laksh
f52cb3bbe0 Make requested changes 2021-09-27 01:45:33 +05:30
Laksh
bc3139e5f9 Fix Settings import 2021-09-25 15:37:07 +05:30
Koitharu
9d249904bd
Toggle all subscriptions notification mode 2021-09-07 13:30:26 +03:00
Koitharu
a5b9fe4c35
Refactor FeedLoadService to use it within the notification worker 2021-09-07 13:30:26 +03:00
Koitharu
e0c674bc9e
Move player notification settings into appearance section 2021-09-07 13:30:25 +03:00
Vasiliy
da9bd1d420
Notifications about new streams 2021-09-07 13:30:16 +03:00
evermind
669a35bc78 check immediately for updates if user enables 'check for updates setting'
- Convert CheckForNewAppVersion to IntentService
- reset expire date to 0 after user enables check for updates setting
2021-09-02 07:20:35 +02:00
Stypox
cfdcb92fa3
Always use our strings, not android ones 2021-08-30 16:37:01 +02:00
Stypox
039bd5d413
Rename string finish to ok, as its content was "OK" 2021-08-30 16:36:57 +02:00
Tobi
0787d62254
Merge pull request #6820 from Stypox/picker-mime-type
Provide mime type to file picker to gray out unselectable files
2021-08-26 21:39:35 +02:00
Stypox
d37ee1e0dc
First run migrations, then setDefaultValues, since the latter requires the correct types 2021-08-24 18:16:17 +02:00
Stypox
1d33e7ab49
Allow choosing which types of search suggestions to show
local, remote, both, none
Replacing the old on-off setting
2021-08-24 18:16:16 +02:00
Stypox
fcef783bbb
Replace UniversalImageLoader with Picasso 2021-08-24 10:56:25 +02:00
Stypox
32dffb577c
Provide mime type to file picker to gray out unselectable files 2021-08-01 13:52:32 +02:00
TacoTheDank
50f3b08c59 Consolidate edittext alert dialogs into one layout 2021-07-27 13:31:58 -04:00
Stypox
baa12c7069
Merge pull request #6536 from TacoTheDank/moar-onactivityresult
More onActivityResult deprecation fixes
2021-07-18 10:24:00 +02:00
Tobi
1584028995
Merge pull request #6531 from XiangRongLin/immediat_pref_commit
Remove option to immediately commit pref changes on import
2021-07-14 09:48:58 +02:00
Mohammed Anas
62b4f333bb
Don't enable SAF on Fire TV (#6516) 2021-06-20 19:01:06 +00:00
TacoTheDank
e5a1438673 Fix onActivityResult deprecation in DownloadSettingsFragment 2021-06-20 14:11:00 -04:00
XiangRongLin
785c0376f8 Remove variable ContentSettingsFragment.lastImportExportDataUri
Instead pass the value through the methods as parameter
2021-06-20 09:30:59 +02:00
XiangRongLin
0bdf8de38e Resolve sonar issues in ContentSettingsFragment
https://sonarcloud.io/organizations/teamnewpipe/rules?open=java%3AS2885&rule_key=java%3AS2885

https://sonarcloud.io/organizations/teamnewpipe/rules?open=java%3AS112&rule_key=java%3AS112
2021-06-20 09:30:59 +02:00
XiangRongLin
9767e98e50 Remove option to immediately commit pref changes on import
System is now not restarted with `System.exit(0)`.
Instead it is done properly by finishing the activity and restarting the activity. This allows preference changes which are queued up asynchronously through `apply` to be applied.
2021-06-20 09:17:55 +02:00
TacoTheDank
79deff3261 Annotate some overridden methods and parameters as NonNull 2021-06-19 18:37:02 -04:00
Stypox
74ad488f4a
Merge pull request #6394 from TacoTheDank/androidx-fragment-134
Update AndroidX Fragment to 1.3.4
2021-06-18 13:14:30 +02:00
danielmbutler
90de75968d Replaced System.Exit calls with FinishAffinity and Start Activity calls
Implemented "RestartApp" method defined in NavigationHelper.java.
 This method is used in ExitActivity.java and ContentSettingsFragment.java
2021-06-17 17:18:15 +01:00
TacoTheDank
aa4e5da146 Fix onActivityResult deprecation in ContentSettingsFragment 2021-06-15 22:08:55 -04:00
TacoTheDank
e4885e3c52 Fix some older deprecations from previous Fragment versions 2021-06-15 22:08:25 -04:00
Stypox
a2eead521f
Merge pull request #6346 from Imericxu/tabs-style-check
Resolve Tabs style checks
2021-06-08 14:49:14 +02:00
Stypox
a2fd5ae20c
Update app/src/main/java/org/schabi/newpipe/settings/tabs/Tab.java 2021-06-08 14:45:00 +02:00
Stypox
543440e38d
Update app/src/main/java/org/schabi/newpipe/settings/tabs/Tab.java 2021-06-08 14:44:54 +02:00
Stypox
2a99e0e435
Reimplement storing backup import/export path
#6319 and #6402 were reverted before adding SAF changes, and have been readded at the end of SAF changes
2021-06-08 10:41:24 +02:00
Stypox
114dc8ffa0
Pass mime type so that SAF treats file extension correctly 2021-06-08 10:40:45 +02:00
Stypox
bcb1cf6603
Improve SAF switch descriptions in settings 2021-06-08 10:40:45 +02:00
Stypox
1e8b3826dc
Add setting migration to promote using SAF 2021-06-08 10:40:45 +02:00
wb9688
febb21a01d
Fix non-SAF actions 2021-06-08 10:40:44 +02:00
wb9688
cb4e6159c4
Use file picker for export DB 2021-06-08 10:40:44 +02:00
wb9688
1164ea52f9
Move Stored(File|Directory)Helper into NewPipe 2021-06-08 10:40:44 +02:00
wb9688
0f75024e03
Support SAF properly 2021-06-08 10:40:44 +02:00
Stypox
1e09a1768e
Revert all commits related to ContentSettingsFragment
Revert "Annotate methode parameters as NonNull"
This reverts commit 004907d306.

Revert "Commit path immediately when import backup"
This reverts commit 05eb0d0fbe.

Revert "Set ImportExportDataPath only on successful import"
This reverts commit f13a1b04e6.

Revert "Set ImportExportDataPath only on successful export"
This reverts commit fd4408e572.

Revert "Invert if condition in ContentSettingsFragment.setImportExportDataPath for better readability"
This reverts commit 92ab9cae27.

Revert "Move ContentSettingsFragment.isValidPath to helpers and add unit test for it."
This reverts commit fa2b11b768.

Revert "Save backup import/export location for feature import/exports"
This reverts commit 82f43ac6a6.

Remove FilePathHelperTest file
2021-06-08 10:40:44 +02:00
XiangRongLin
004907d306 Annotate methode parameters as NonNull 2021-05-31 15:09:57 +02:00
XiangRongLin
05eb0d0fbe Commit path immediately when import backup 2021-05-31 12:40:14 +02:00
XiangRongLin
f13a1b04e6 Set ImportExportDataPath only on successful import
Also set the folder instead of the file itself as path
2021-05-31 12:38:21 +02:00
XiangRongLin
fd4408e572 Set ImportExportDataPath only on successful export 2021-05-31 12:36:21 +02:00
Eric Xu
448989f32f Add PlaylistTab.hashCode() matching equals 2021-05-26 12:01:30 -04:00
Eric Xu
2fc26bc154 Refactor PlaylistTab.equals 2021-05-26 12:01:30 -04:00
Eric Xu
1812249d37 Add ChannelTab.hashCode() matching equals 2021-05-26 12:01:30 -04:00
Eric Xu
14bbaccb9f Refactor ChannelTab.equals 2021-05-26 12:01:30 -04:00
Eric Xu
d2b03afcf4 Add KioskTab.hashCode() matching equals 2021-05-26 12:01:30 -04:00
Eric Xu
1cac3895dc Refactor KioskTab.equals 2021-05-26 12:01:30 -04:00
Eric Xu
01aab25889 Add Tab.hashCode() to go with equals 2021-05-26 12:01:30 -04:00
Eric Xu
96d731dfc7 Refactor equals method 2021-05-26 12:01:30 -04:00
Alireza Tofighi
92ab9cae27 Invert if condition in ContentSettingsFragment.setImportExportDataPath for better readability 2021-05-21 20:24:57 +04:30
Alireza Tofighi
fa2b11b768 Move ContentSettingsFragment.isValidPath to helpers and add unit test for it. 2021-05-21 20:21:58 +04:30
Alireza Tofighi
82f43ac6a6 Save backup import/export location for feature import/exports 2021-05-17 21:57:27 +04:30
TacoTheDank
e75d0de135 Migrate rest of AlertDialogs to AppCompat 2021-04-04 10:26:38 -04:00
krlvm
e484339cca
Merge branch 'dev' into daynight 2021-04-03 00:08:26 +03:00
Stypox
5d6a568308
Fix random NullPointerException in NotificationActionsPreference 2021-03-31 09:12:47 +02:00
krlvm
e9c60eff85
Cleanup 2021-03-30 00:03:30 +03:00
krlvm
c906cb57ee
Fix colors in setting fragments, cleanup 2021-03-29 21:19:17 +03:00
krlvm
67942a906a
Fix colors in PeerTube Settings Fragment 2021-03-28 19:36:07 +03:00
Stypox
daa5b7827a
Merge pull request #5879 from TacoTheDank/clean-oncreatepreferences
Clean up unnecessary onCreate in settings fragments
2021-03-28 10:48:10 +02:00
krlvm
fd14c8cdce
Fix Dark elements in Light Theme 2021-03-27 17:46:05 +03:00
Stypox
08d8f2564a
Merge pull request #5882 from TacoTheDank/fragmentcontainerview
Replace FrameLayout with FragmentContainerView where applicable
2021-03-27 08:31:32 +01:00
krlvm
b3e2418b93
Migrate to DayNight Theme 2021-03-26 23:08:25 +03:00
Stypox
0fcaf20221
Fix settings switches are not red anymore
Reverts part of 731c65cd59
2021-03-24 10:16:24 +01:00
TacoTheDank
6a9d5fd4cc Replace FrameLayout with FragmentContainerView where applicable 2021-03-22 17:46:06 -04:00
TacoTheDank
a83106f717 Clean up unnecessary onCreate in settings fragments 2021-03-22 16:38:36 -04:00
Stypox
731c65cd59
Refactor ThemeHelper 2021-03-18 12:39:29 +01:00
bopol
a85e8a29ff
Use a list for night themes
Also remove unused strings
2021-03-18 12:12:04 +01:00
bopol
22b2f52f8c
Use a switch preference to follow device theme 2021-03-18 11:23:55 +01:00
Stypox
463dd8ea74
Completely remove return activity, now outdated 2021-03-12 23:21:54 +01:00
Stypox
1fc8e4c148
Optimize imports and solve checkstyle issues 2021-03-12 23:21:53 +01:00
Stypox
c43bca6007
Add report/solve-recaptcha button in error panel
It will be shown even when nothing could be loaded not due to a network error, and the user can choose to ignore or report it.

Also improve error reporting arguments
Also completely refactor error activity
Also improve some code here and there
2021-03-12 23:21:49 +01:00
Stypox
553b80164b
Move all error-related classes into error package 2021-03-07 17:49:28 +01:00
Stypox
02db971b7c
Set all default settings at the beginning 2021-01-28 18:28:29 +01:00
TiA4f8R
79e98db3bd
Apply the requested changes and little improvements
Apply the requested changes, use ShareUtils.shareText to share an stream in the play queue and optimize imports for Java files, using Android Studio functionality.

Apply the requested changes and do little improvements
Apply the requested changes, use ShareUtils.shareText to share an stream in the play queue and optimize imports for Java files, using Android Studio functionality.
2021-01-16 13:23:42 +01:00
XiangRongLin
716d795970 cleanup 2021-01-03 20:32:16 +01:00
XiangRongLin
fcfdcd1025 Fix ensureDbDirectoryExists 2021-01-03 20:32:16 +01:00
XiangRongLin
af119db1d7 Extract settings file deletion 2021-01-03 20:32:16 +01:00
XiangRongLin
122e80fae9 Remove subclasses from ContentSettingsManagerTest
ExportTest provides no value.
ImportTest creates temporary files even if not needed.
2021-01-03 20:32:16 +01:00
XiangRongLin
8fceffd6fd Introduce NewPipeFileLocator class 2021-01-03 20:32:16 +01:00
XiangRongLin
19cd3a17df Move isValidZipFile to ZipHelper 2021-01-03 20:32:16 +01:00
XiangRongLin
ea91a62c89 Adjust ExportTest to new DI with FileLocator 2021-01-03 20:32:16 +01:00
XiangRongLin
cef791ba1b Introduce NewPipeFileLocator class
It handles locating specific NewPipe files based on the home directory of the app.
2021-01-03 20:32:16 +01:00
XiangRongLin
f78a7fa630 Extract import database logic in ContentSettingsManager 2021-01-03 20:32:16 +01:00
Isira Seneviratne
14a2171035 Use Objects.requireNonNull(). 2021-01-02 09:36:33 +05:30
Isira Seneviratne
d6121c8e21 Use view binding in SettingsActivity. 2020-12-19 04:22:01 +05:30
XiangRongLin
a7723373a0 Fix compile error caused by auto merging
#5176 changed `homeDir` from type `String` to `File`. #5059 was based on `homeDir` being a `String`. It was incorrectly auto-resolved by git.
2020-12-15 20:26:38 +01:00
Stypox
d46c7eb8fe
Merge pull request #5059 from XiangRongLin/content_settings_manager
Extract export database logic into own class
2020-12-15 10:34:32 +01:00
Stypox
276f50a944
Merge pull request #5178 from Isira-Seneviratne/Use_ActivityCompat_recreate
Use ActivityCompat.recreate().
2020-12-15 09:49:14 +01:00
Isira Seneviratne
807e4d4af9 Use ActivityCompat.recreate(). 2020-12-15 13:55:05 +05:30
Isira Seneviratne
30613b7064 Use ContextCompat.getDataDir(). 2020-12-15 08:02:25 +05:30
XiangRongLin
f7f00293cc Extract export database logic into own class
- Separate it from the UI.
- Add happy path unit test.
2020-12-04 18:30:29 +01:00
Stypox
f0ca916432
Update most dependencies 2020-11-22 14:03:10 +01:00
Isira Seneviratne
95333d37c8 Use try-with-resources. 2020-11-21 13:47:13 +05:30
Isira Seneviratne
340b92e32b Convert ErrorInfo to Kotlin and use the Parcelize annotation. 2020-11-21 12:47:35 +05:30
TacoTheDank
2669ba944d Correct some other small lints 2020-11-19 18:54:27 -05:00
TacoTheDank
39e5d8ccc2 Lint: Make a bunch of stuff final 2020-11-18 17:50:00 -05:00
Stypox
9e7fb4d21a
Merge pull request #4771 from Stypox/fix-playlist-select
Fix playlist select dialog and do some refactoring
2020-11-14 11:21:20 +01:00
Isira Seneviratne
ef5084036c Use RxJava instead of AsyncTask to check for new app versions. 2020-11-05 11:06:50 +05:30
Stypox
1f73572dd3
Fix playlist select dialog and do some refactoring 2020-11-02 14:24:39 +01:00