* Enhanced the `isBookMarkExist` method, addressing a bug that prevented the addition of new bookmarks for the same file. The method has been refactored for improved functionality.
* In the debug version, added informative logs to provide developers with insights into the bookmark-saving functionality.
* We now save this library information into a file named `library.txt` and subsequently read from it to retrieve file paths and favicons.
* The test cases have been refactored to accommodate this new functionality.
* The `ObjectBoxToLibkiwiMigrator` code has also been enhanced. With this change, we now save books in the library for their favicon and zimFilePath, resulting in a refactor and improvement of this class's functionality and its associated test cases.
* The process of writing bookmarks and library data to file has been enhanced. Now, this is performed asynchronously in a background thread to mitigate potential data loss.
* Additionally, several other improvements have been made throughout the codebase.
* We introduced a Flowable list in LibkiwixBookmarks to observe live changes on the UI. Previously, the UI was not updating after deleting bookmarks on the BookmarkScreen, and toggling bookmarks in the reader screen was also not reflecting the changes. To address this, we created a Flowable list and are now observing it whenever bookmarks are added or removed in the library.
* Since we are now using fd (FileDescriptor) to read the zim file from the asset folder. Currently, 'KiwixServer' is unable to host zim files via fd. This feature is temporarily hidden for custom apps. We will re-enable it for custom apps once the issue is resolved.
* In `ZimHostFragment`, we show Zim files that are saved in the database. These files are typically saved when downloading Zim files. In a custom app, where Zim files are already included within the app and not downloaded separately that's why they are not showing on the `ZimHostFragment`, we have addressed this issue by saving the Zim files in the database to ensure they appear in the `ZimHostFragment`.
* Regarding the `FileDescriptor`, there are no file objects available because we read Zim files using `FileDescriptor`. To address this, we have created a `demo.zim` file to save it in the database so that it will be displayed in the `ZimHostFragment`. We handle this file within the `KiwixServer`. When the current Zim file is `demo.zim`, we create an `Archive` object with the `FileDescriptor` to host the Zim file on the `KiwixServer`.
* The problem was that we were saving the note name combined with `zimFileTitle` and `articleTitle`. When opening the saved note from `NotesFragment`, it retrieved the `noteTitle` from the database, which already contained the combined name. Subsequently, when saving the note again, it redundantly combined the name. To resolve this issue, we now extract the `articleName` when updating notes in `NotesFragment`, ensuring that it updates existing notes instead of creating new ones.
* Now we are using fileDescriptor for custom apps to read zim file from asset folder, so we have improved our notes saving functionality according to this change.
* Since custom apps only have a single zim file, there is no need to display these switches, which can potentially confuse users. Therefore, we have hidden these switches in custom apps.
* Improved the permission request scenario for 'MANAGE_EXTERNAL_STORAGE' in Android 13. In the non-play store variant, we were not prompting users to grant this permission, and they were unaware that it was necessary to access the ZIM files in their storage. To resolve this issue, we now request this permission.
* In the `ZimHostFragment`, there were occasional test failures due to specific conditions. When reattempting the test, it failed to detect the 'WiFi connection detected' dialog because the server was already running. To resolve this issue, we have improved our test case. Now, we first check if the server is already running. If it is, we close the server before running the test case.
* In previous test failures within the `ZimHostFragment`, there were instances where the zim file was unselected, causing our test case to fail to locate the required views. To mitigate this, we now check whether the zim file is selected. If it's not selected, we first select the zim file before running the test case.
* n the `LocalLibraryFragment` test, there were cases where it was unable to locate the 'file_management_no_files' view due to variations in the order of test cases. This occurred because a zim file was sometimes present in the `LocalLibrary`. To address this, we now check for the presence of any zim files in the `LocalLibrary` and delete them before running our test case.
* We have made improvements to `ZimHostFragmentTest`. We added the `ACCESS_FINE_LOCATION` permission, which is required for running this test case on real devices. Additionally, we have enhanced the permission array and removed unnecessary permissions from the test case.
* When the application goes in the background from `ZimHostFragment`, `KiwixReaderFragment/ZimHostFragment` without starting the Service then the `ReadAloudService`, and `HotspotService` variables are not used and GC try to clear those objects but we are not clearing those objects, that's why memory leak is happening. So now we have free those objects if they are not in use.