8300 Commits

Author SHA1 Message Date
Shaun Burch
f40185de2a #1553 Remove ZXing comment 2024-07-01 22:01:53 -04:00
Shaun Burch
9e1a212cb2 #1553 Add QR to hotspot notification 2024-07-01 22:01:53 -04:00
Shaun Burch
7f19919317 #1553 PR Feedback
- Rename to QRCodeDialog
- Move to core module
- Inject GenerateQR
- Remove preview string
2024-07-01 22:01:53 -04:00
Shaun Burch
4ae59f1369 #1553 Fix testZimHostFragment 2024-07-01 22:01:53 -04:00
Shaun Burch
fa1113fc00 #1553 Tests 2024-07-01 22:01:53 -04:00
Shaun Burch
f2e7e7a3c0 #1553 Use String for share by QR 2024-07-01 22:01:53 -04:00
Shaun Burch
a8d27596fe #1553 Touch up QR dialog 2024-07-01 22:01:53 -04:00
Shaun Burch
3c8f5a44e9 #1553 Generate & show QR 2024-07-01 22:01:53 -04:00
Shaun Burch
f02d4b8f03 #1553 Add Share by QR 2024-07-01 22:01:53 -04:00
Kelson
3c0397d9fc
Merge pull request #3918 from kiwix/Fixes#3912
Fixed: latency in showing whether a bookmark is added in the toggle button.
2024-07-01 22:04:05 +02:00
MohitMaliFtechiz
5f9ef86733 Fixed: latency in showing whether a bookmark is added in the toggle button.
* Previously, we are checking the bookmark is added or not when a page is fully loaded in the webView. In the meantime previously set bookmark toggle is showing e.g. if the previous page is added as a bookmark then until the page is fully loaded the toggle is showing that the current is added as a bookmark. However, this new page is not added as a bookmark.
* To fix this latency, we moved our `updateUrlProcessor()` method to the `webViewProgressChanged` method to update the bookmark toggle when a page starts loading in the webView. This fixes the latency in updating the bookmark toggle.
2024-07-01 17:55:38 +05:30
Kelson
ad9e7e6b5b
Merge pull request #3914 from kiwix/Fixes#3908
Displaying the ZIM title in the notification instead of the file name.
2024-06-29 13:41:35 +02:00
MohitMaliFtechiz
7015812411 Displaying the ZIM title in the notification instead of the file name.
* In the notification, the information coming from `fetch` does not include the ZIM title (only the file name is currently shown in the notification). However, we have the `FetchDownloadDao` where we save all the details related to downloads. We have created a method in `FetchDownloadDao` that retrieves the downloadEntity from the file name, which includes the ZIM title, and we are now displaying that title in the notification.
2024-06-29 14:56:25 +05:30
Kelson
e960848b2c
Merge pull request #3911 from kiwix/Fixes#3907
Fixed: Sometimes migration test took longer in migration in lower device(e.g. API level 25) and fails the test case.
2024-06-28 16:55:55 +02:00
MohitMaliFtechiz
a283e9491f Fixed: Sometimes migration test took longer in migration in lower device(e.g. API level 25) and fails the test case.
* Increased the migration timing a little bit as migration sometimes takes a few milliseconds more on CI.
2024-06-28 18:43:27 +05:30
Kelson
9c4ae35c42
Merge pull request #3906 from kiwix/update_changelog_file_for_3.11.1
Updated CHANGELOG file to show the changes made in milestone `3.11.1`.
3.11.1
2024-06-27 14:28:19 +02:00
MohitMaliFtechiz
5dd16354f9 Updated CHANGELOG file to show the changes made in milestone 3.11.1. 2024-06-27 17:49:28 +05:30
Kelson
cbfb5e262a
Merge pull request #3876 from kiwix/translatewiki
Localisation updates from https://translatewiki.net.
2024-06-27 14:11:23 +02:00
translatewiki.net
0f6232cac6 Localisation updates from https://translatewiki.net. 2024-06-27 14:11:08 +02:00
Kelson
c6b025f04a
Merge pull request #3905 from kiwix/upgrade_kiwix_version_to_3.11.1
Upgraded the kiwix version to 3.11.1
2024-06-27 14:09:49 +02:00
MohitMaliFtechiz
4e96703b11 Upgrade the kiwix version to 3.11.1 2024-06-27 14:08:04 +02:00
Kelson
262b4e5d75
Merge pull request #3904 from kiwix/Fixes#3901
Fixed: A `NotSerializableException` was attached to the crash logs instead of the actual crash logs when there was an error in the coroutine.
2024-06-27 14:07:45 +02:00
MohitMaliFtechiz
0d5a330d3f Improved logging for exceptions that do not have a stack trace. 2024-06-27 15:52:16 +05:30
MohitMaliFtechiz
a2ac6429a7 Fixed: A NotSerializableException was attached to the crash logs instead of the actual crash logs when there was an error in the coroutine.
* The serialization issue was fixed in coroutine version `1.7.0`, so we have upgraded the coroutine dependency to `1.7.0` to address this issue.
* In the new version of coroutines, `ConflatedBroadcastChannel` is replaced with `StateFlow`, so we have refactored our code to use `StateFlow`.
* Fixed some detekt issues which occurs after upgrading this dependency.
2024-06-27 14:50:23 +05:30
Kelson
e4c3d1a6e8
Merge pull request #3900 from kiwix/Fixes#3899
Fixed: `SQLiteConstraintException` when inserting the same id item of hisotry/notes in room database.
2024-06-27 08:33:48 +02:00
MohitMaliFtechiz
91eacae0f4 Improved DeletePageItemsTest test. 2024-06-26 22:35:24 +05:30
MohitMaliFtechiz
13233e0dcc Fixed: SQLiteConstraintException when inserting the same id item of hisotry/notes in room database.
* id is the primary key for notes/history and when there is an already id available in the room database, and if there is the same id present in the objectbox database and we try to put that entity in the room it gives the SQLiteConstraintException. To fix this we have modified our saving functions of history and notes. If there is already an ID that exists in the room database that we are trying to put in the database it will set the ID to 0 so that the room will automatically assign the ID to that entity and our history/notes will prevent to be lost.
* Added the test cases to properly test these scenarios.
2024-06-26 22:25:18 +05:30
Kelson
2dd933e7ba
Merge pull request #3898 from kiwix/Fixes#3897
Fixed: `getDirectAccessInformation()` method throw the `InvocationTargetException` and crash the application.
2024-06-26 13:13:49 +02:00
MohitMaliFtechiz
352c4038d3 Improved the exception handling. 2024-06-26 15:29:31 +05:30
MohitMaliFtechiz
a902f15480 Fixed: getDirectAccessInformation() method throw the InvocationTargetException and crash the application. 2024-06-26 15:29:24 +05:30
Kelson
4a30af5462
Merge pull request #3893 from kiwix/Fixes#3889
Fixed: Sometimes not all Bookmarks are showing.
2024-06-25 21:44:45 +02:00
MohitMaliFtechiz
f209aa6c6a Fixed BookmarkStateTest, BookmarkViewModelTest, and ShowDeleteBookmarksDialogTest. 2024-06-25 23:22:15 +05:30
MohitMaliFtechiz
38e4fe41cb Fixed DownloadTest, initialDownload. The Library order and zim file name is changed so these test cases are failing so we have implemented a generic approach to not dependent on zim file name. 2024-06-25 23:22:08 +05:30
MohitMaliFtechiz
b0c5db4ad3 Added test cases for testing all the saved bookmarks should show on the bookmarks screen. 2024-06-25 23:22:02 +05:30
MohitMaliFtechiz
17e630c40b Fixed: Sometimes not all Bookmarks are showing.
* We have implemented `setHasStableIds(true)` in our RecyclerView, which handles data updates efficiently and enhances view recycling. It also provides smooth animations when data is refreshed. However, it requires unique IDs to perform these operations effectively. Since our bookmarks are stored in libkiwix and do not have unique IDs (database IDs), this sometimes results in duplicate data being displayed in the list instead of the actual data, as the lack of unique IDs causes the same data to be repeated when recycling non-visible items.
* To fix this, we have explicitly provided unique IDs by combining a UUID with the maximum value of a long. This ensures that RecyclerView can efficiently handle large data sets.
2024-06-25 23:21:55 +05:30
Kelson
4a6fecd2d6
Merge pull request #3887 from kiwix/Fixes#3884
Fixed outdated text showing when a zim file could not open.
2024-06-20 09:53:42 +02:00
MohitMaliFtechiz
a1f33ca18f Fixed outdated text showing when a zim file could not open.
* Outdated text was showing when a zim file could not open in the kiwix, this text was for the older UI, and now we have removed the "Device Tab" from the "Library" screen so this text is outdated and misleading the users. so we have changed this text according to the new UI.
2024-06-20 12:13:53 +05:30
Kelson
99fe8982fb
Merge pull request #3885 from kiwix/Fixes#3877
Fixed: Xapian crash scenarios.
2024-06-20 06:48:50 +02:00
MohitMaliFtechiz
193c0d1de4 Re-enabled the retry logic in test case. 2024-06-20 01:13:58 +05:30
MohitMaliFtechiz
1fcbe67e20 Added instrumentation test cases to test the search functionality.
* Testing the render method with different scenarios to ensure that libzim do not crash due to broken call stack.
2024-06-20 00:03:25 +05:30
MohitMaliFtechiz
eb95bddf6c Added unit test cases for testing the previous job is cancelled properly. 2024-06-19 19:05:49 +05:30
MohitMaliFtechiz
e9934376bb Fixed test cases are not running. 2024-06-19 18:04:59 +05:30
MohitMaliFtechiz
1dfac37559 Fixed SearchViewModelTest and SearchStateTest. 2024-06-19 17:24:29 +05:30
MohitMaliFtechiz
9875ad57eb Moved the global mutex to the SearchResultsWithTerm class to prevent concurrency issues.
* Applied mutex locking in the SearchState class to ensure safe access to search results when users search for different terms.
2024-06-19 15:27:16 +05:30
MohitMaliFtechiz
c405025232 Improved the getVisibleResults method to check if the current job is cancelled before requesting suggestion results from libzim.
* Enhanced the loadMoreSearchResults method to accommodate this modification.
* Refined the render method to effectively cancel any previously running tasks upon its subsequent execution.
2024-06-19 14:37:39 +05:30
MohitMaliFtechiz
8865aac1ba Fixed: Xapian crash scenarios.
* Enhanced retrieval of suggestion lists from libzim.
* Implemented task cancellation if the fragment is not visible.
* Refactored getVisibleResults into a suspend method to ensure efficient job cancellation.
* Handled exceptions thrown by coroutines.
* Transitioned to Kotlin Flow instead of Flowable after making getVisibleResults suspend.
* Employed lifecycleScope for coroutine launch to prevent unnecessary calls when the fragment is hidden.
2024-06-18 20:52:56 +05:30
Kelson
9f949652f2
Merge pull request #3880 from kiwix/Fixes#3878
Fixed ServiceWorker Initialization Issue
2024-06-15 13:15:50 +02:00
MohitMaliFtechiz
4c3af12427 Initlizing the ServiceWorker in onCreate method of CoreApp class so that all necessary application setup is complete before the service worker is initialized and provides better control over the initialization sequence. 2024-06-15 12:46:10 +02:00
MohitMaliFtechiz
824aa96d20 Fixed ServiceWorker Initialization Issue
* ServiceWorker was being initialized every time the `CoreApp` instance was created. When the application crashed, `ErrorActivity` was invoked to send a crash report, running in a separate process. In this new process, the ServiceWorker was also being initialized.
* Upon user interaction (e.g., clicking "No Thanks" to relaunch the app), the application returned to the main process, leading to a second initialization of the ServiceWorker with the same data directory, causing a crash.
* Since `ErrorActivity` does not require any WebView-related functionality, it is unnecessary to initialize the ServiceWorker in this process.
* The fix involves modifying the initialization code to ensure the ServiceWorker is only initialized in the main process of the application.
2024-06-15 12:46:10 +02:00
Kelson
ab5fb35085
Merge pull request #3801 from kiwix/Fix#3511
Fixed: Not able to upload 512MB+ custom apps anymore.
2024-06-15 12:44:59 +02:00