Fix how default actions are picked and add in default app actions
as options for both debrid and magnet defaults. Kodi shows the
action choice sheet with the DisclosureGroup dropped down.
The new Kodi server framework also wasn't implemented in the Kodi
wrapper. Fix that.
Finally, add some iOS 14 fixes and repair the autocorrect search
setting to actually work.
Signed-off-by: kingbri <bdashore3@proton.me>
Multiple servers can be added to Ferrite to playback from any Kodi
server that the user wants. This also adds the ability to have
friendly names which makes it easier to select what server to play on.
Each server shows the user whether it's online or not through Kodi's
JSONRPC ping method.
Signed-off-by: kingbri <bdashore3@proton.me>
Adds support for playing links on a preset Kodi server. This is
less featured than the Ferrite companion, but should still work
without a problem.
Signed-off-by: kingbri <bdashore3@proton.me>
The overall UI of Ferrite has been changed to make animations smoother
and streamline the experiences.
A new search filter interface has been added for all iOS versions,
but iOS 15 and up have smooth UI applied due to bugs with searchbars
in iOS 14 (which shouldn't even have a searchbar in the first place).
Also fix the plugin fetching logic to not listen to a combine publisher
and instead use a notification that is easier to control.
Signed-off-by: kingbri <bdashore3@proton.me>
This commit adds support for viewing a user's AllDebrid magnet list.
AllDebrid does not save unlocked links, but they do save which magnets
a user has queried.
Also clean up various functions in DebridManager.
Signed-off-by: kingbri <bdashore3@proton.me>
Magnets are expressed in two different ways: a hash and a link. Both
of these mean the same thing with a magnet link giving more information
if required.
However, there was a disconnect if a hash was present or a link was
present and required many steps to check which was available. Unify
magnets by creating a parent structure that attempts to extract
the hash or create a link in the event that either parameter isn't
provided.
Replace everything except bookmarks (to prevent CoreData complaints
and unnecessary abstraction) to use the new Magnet system.
Signed-off-by: kingbri <bdashore3@proton.me>
Add the ability to view a user's Premiumize files in Ferrite. Files
can be deleted from a user's account directly in Ferrite's list.
Signed-off-by: kingbri <bdashore3@proton.me>
RealDebrid saves a user's unrestricted links and "torrents" (magnet
links in this case). Add the ability to see and queue a user's RD
library in Ferrite itself.
This required a further abstraction of the debrid manager to allow
for more types other than search results to be passed to various
functions.
Deleting an item from RD's cloud list deletes the item from RD as well.
NOTE: This does not track download progress, but it does show if a
magnet is currently being downloaded or not.
Signed-off-by: kingbri <bdashore3@proton.me>
Premiumize has a dynamic upper limit of 107-110 (from testing)
hashes per request. To play it safe, cache requests are split by
100 and executed in parallel as 2 (or more) requests.
Signed-off-by: kingbri <bdashore3@proton.me>
Premiumize is another debrid provider. Add support in addition
to other debrid services.
Add a unified Magnet type that encloses both the link and hash
when needed for certain services.
A universal ASAuthenticationSession has been added to make implicit
authentication easier for services that support it.
Clean up declarations of certain variables that were mismanaged
during the debrid decentralization process.
Signed-off-by: kingbri <bdashore3@proton.me>
AllDebrid is another debrid provider. Add support to Ferrite in
addition to RealDebrid.
The overall debrid login backend has changed to accomodate for a more
agnostic app structure where more services can be added as needed.
Also add some cosmetic changes to search so filters can be added while
searching for a phrase.
Signed-off-by: kingbri <bdashore3@proton.me>
Use strict concurrency checking in Xcode 14 to find misuses with
Swift concurrency.
Cleanup files and rearrange them along with fixing comment headers.
Signed-off-by: kingbri <bdashore3@proton.me>
To declutter a RealDebrid user's library, check if the file and
unrestricted link exist and serve those existing links. Otherwise
perform a download like normal.
Sometimes RealDebrid deletes cached items, but still keeps them on
instant availability. Add a way to tell the user that the item
is downloading along with an option to cancel it.
Also remove unnecessary published variables from viewmodels
Signed-off-by: kingbri <bdashore3@proton.me>
Bookmarks are added through search results and can be accessed through
the library. These can be moved and deleted within the list.
Add a RealDebrid instant availability cache for bookmark IA status
to not overwhelm the API. Instant availability results are fresh on
every search results since the cache is cleared.
Also don't require a source API object to be present for the API parser
button in source settings. If a JSON parser exists for a source, allow
the option to be presented.
Signed-off-by: kingbri <bdashore3@proton.me>
Updates are sent via an alert on starting the app. This can be
disabled in the settings menu.
A full version struct has been completed for flexible comparisons.
Version history can also be viewed in settings in case a user wants
to download an earlier version of the app.
Updates track Github releases.
Signed-off-by: kingbri <bdashore3@gmail.com>
When a search result is selected, there is usually a delay due to
the debrid dance of API routes for grabbing a download link to stream.
Add a loading indicator and prevent any other tasks from loading
unless the user cancels it.
iOS 14.5 was a huge update which added many QoL SwiftUI changes that
are consistent to modern iOS versions.
However, Ferrite supports iOS versions less than 14.5, mainly 14.3.
More fixes had to be added to make sure UI is consistent across
all OS versions.
Signed-off-by: kingbri <bdashore3@gmail.com>
These sources will be converted to be more flexible with JavaScript
in the future.
The source catalog is populated by adding a source list in settings
then installing a source from the catalog.
Sources can be enabled or disabled when using Ferrite.
Signed-off-by: kingbri <bdashore3@gmail.com>
Batch torrents are torrents that have multiple files bundled within
one torrent file.
RealDebrid does support these, but it is difficult to get them to work.
The main flow requires setting a specific combination in RealDebrid
to allow for link generation. However, this is not intuitive to users
and is bad API design on RealDebrid's part.
Ferrite's implementation presents users with all the possible files
from batches (duplicates deleted) and selects the user-chosen file
to download. That way, only the user chosen file is presented to
play on an external video player.
This still needs work for optimization purposes, but this commit
does produce a working build.
Signed-off-by: kingbri <bdashore3@gmail.com>
The instantAvailability endpoint is now decoded using Codable
and does not have any ambiguity.
Batches are now checked, but still not accounted for due to how
RD handles batches from this endpoint. All batch links are not
supported for instant streaming from Ferrite until support is added.
Thanks to Skitty for helping out with decoding the endpoint.
Signed-off-by: kingbri <bdashore3@gmail.com>
Every request has to add an authentication header. If the response
is 401 (Unauthorized), log the user out of RealDebrid.
Signed-off-by: kingbri <bdashore3@gmail.com>