7778 Commits

Author SHA1 Message Date
MohitMaliFtechiz
69392506bf Fixed: Selected files count is not showing initially in LocalLibrary screen.
* Initially `ActionMode` is null when we are selecting ZIM files that's why it is not showing the selected book count in the ActionMode title. So to fix this we are setting the value when the actionMode is created.
2024-02-25 21:00:35 +01:00
Kelson
6512ef483f
Merge pull request #3719 from kiwix/Fix#3718
Fixed: Bookmark screen title is set as "Kiwix" if we open the Bookmarks screen from Widget
2024-02-25 21:00:10 +01:00
MohitMaliFtechiz
a8c543965d Fixed: Bookmark screen title is set as "Kiwix" if we open the Bookmarks screen from Widget
* The encountered issue stemmed from setting the title directly on the toolbar. When navigating from the widget, the sequence involved opening the CoreReaderFragment followed by the immediate launch of the bookmark screen. During this rapid transition, the toolbar was continuously receiving updates, but these updates were not occurring in a synchronized manner. As a consequence, the title set on the toolbar was not being reflected accurately. To address this timing inconsistency, we opted to set the title on the actionBar instead of directly on the toolbar. By doing so, we are leveraging the actionBar as a higher-level component, which internally manages the presentation of the title on the toolbar. This approach ensures a more synchronized update of the title, particularly crucial in scenarios involving swift fragment transitions, such as opening the bookmark screen from the widget. Consequently, the change to actionBar.title provides a more reliable and synchronized mechanism for managing the title, resolving the issue encountered during rapid navigation.
* Removed the unnecessary `UnspecifiedImmutableFlag` lint suppression from CoreSearchWidget.
2024-02-23 18:36:58 +05:30
Kelson
5fa7bdbf26
Merge pull request #3697 from kiwix/translatewiki
Localisation updates from https://translatewiki.net.
2024-02-22 19:04:46 +01:00
translatewiki.net
ebdc5443fe Localisation updates from https://translatewiki.net. 2024-02-22 19:04:26 +01:00
Kelson
f49433ffdb
Merge pull request #3717 from amire80/patch-1
Fix "go to" spelling
2024-02-22 19:03:50 +01:00
Amir E. Aharoni
30c9e7b5b9
Fix "go to" spelling
"Goto" is used in some programming languages,
but not in English :)
2024-02-22 09:58:45 -05:00
Kelson
c4d235fdda
Merge pull request #3706 from kiwix/Fix#3701
Fixed: Addressed the touch target size issue reported by the Play Store.
2024-02-21 11:35:16 +01:00
MohitMaliFtechiz
211056c4ff Fixed the close tab icon size issue.
* Created an extension function to set up the SearchView. It now configures the toolTipText and width for the close icon of the SearchView.
* With this extension function, we have applied these properties to every SearchView used in the application, such as in LanguageFragment, SearchFragment, (History/Bookmark/Notes), and OnlineLibraryFragment.
2024-02-21 13:13:43 +05:30
MohitMaliFtechiz
e860cf9aa0 Fixed: Addressed the touch target size issue reported by the Play Store.
* Increased the height and width of the views to align with Play Store policies, while ensuring no impact on the UI (as illustrated in the images below).
2024-02-21 13:05:59 +05:30
Kelson
c79e942fbb
Merge pull request #3705 from kiwix/Fix#3702
Fixed: The Play Store has reported some implementation issues.
2024-02-21 07:45:35 +01:00
MohitMaliFtechiz
959d4f56f1 Fixed: The Play Store has reported some implementation issues.
* Increase the clickable area of the tab switcher to align with the ideal menu item size, ensuring users can easily interact with it.
2024-02-21 11:42:16 +05:30
Kelson
f130269195
Merge pull request #3709 from kiwix/Fix#3703
Fixed: `Low contrast` issue reported by the PlayStore.
2024-02-21 07:01:10 +01:00
MohitMaliFtechiz
31cefdc1a9 Fixed: Low contrast issue reported by the PlayStore.
* Enhanced the contrast of the `mine_shaft_gray600` color to comply with Play Store's recommendation of `4.50.1`. This color is utilized in the book's itemView.
* Implemented the updated color in `IntroScreens` subHeading to resolve the low contrast issue.
* To rectify the contrast issue in the `LanguageFragment`, we increased the opacity of views to align with the recommended contrast.
2024-02-21 07:00:39 +01:00
Kelson
746dd60e5f
Merge pull request #3707 from kiwix/Fix#3700
Fixed: Content labeling issue reported by the playstore.
2024-02-21 06:59:49 +01:00
MohitMaliFtechiz
046f10f465 Added contentDescription for all backButtons/closeButtons of toolbar.
* Added `contentDescription` for "+" button in TabSwitcher.
2024-02-21 06:59:01 +01:00
MohitMaliFtechiz
1a671e53e9 Utilize the toolTip extension function instead of employing TooltipCompat.setTooltipText throughout the code to eliminate redundancy. Additionally, removed comments related to the usage of this method, as the information is already provided in our extension function's comment. 2024-02-21 06:59:01 +01:00
MohitMaliFtechiz
0b7756cf57 Fixed: Content labeling issue reported by the playstore.
* Added content descriptions for all views reported by the Play Store, including RecyclerView, dialog's itemView, pause/resume/stop buttons, and many more.
* Created an extension function to handle both setting the content description to address Play Store accessibility issues and displaying hints to the user using ToolTipText. This function consolidates these tasks in one place, eliminating code duplication.
2024-02-21 06:59:01 +01:00
Kelson
ad09b4c3fa
Merge pull request #3704 from kiwix/Fix#2896
Fixed: Added the ability to press Enter to skip the search.
2024-02-21 06:58:20 +01:00
MohitMaliFtechiz
da897a104e Fixed: Added the ability to press Enter to expedite the search.
* If the search/enter button is pressed and an article is found with the same query, it will directly open that article. Otherwise, it will proceed with the regular search operation as before.
2024-02-16 08:28:12 +01:00
Kelson
f85d6013c2
Merge pull request #3689 from Sagar0-0/develop
#3668 Ripple in Tabs Icon
2024-02-15 12:38:05 +01:00
Sagar
b924daab57 #3668 Comments added for ToolTip uses 2024-02-15 10:23:42 +05:30
Sagar
0411a98c49 #3668 setToolTip method fix 2024-02-15 10:23:42 +05:30
Sagar
a907fa3f42 #3668 Added setToolTip function 2024-02-15 10:23:42 +05:30
Sagar
4b9a309fb1 #3668 ToolTip in tab icons 2024-02-15 10:23:42 +05:30
Sagar
6e4b8dcba8 #3668 Ripple in Tabs Icon 2024-02-15 10:23:42 +05:30
Kelson
f65787b182
Merge pull request #3649 from kiwix/Fix#3643
Fixed: Version `3.9.1` was experiencing occasional crashes when setting the `SuggestionSearcher`.
2024-02-14 07:24:33 +01:00
MohitMaliFtechiz
287503746e Fixed: Version 3.9.1 experienced occasional crashes when setting the SuggestionSearcher.
* The crashes occurred in the Play Store version due to insufficient permissions for opening a file via `fileDescriptor`. To address this issue, we have modified the implementation to use the `file` instead of `fileDescriptor`. This adjustment ensures smooth operation in the non-Play Store version where we have permission to open a file via its path. In the Play Store version, it will display a proper error message to the user, preventing errors thrown by libkiwix.
2024-02-07 11:29:50 +01:00
Kelson
1f078634ae
Merge pull request #3653 from kiwix/Fix#3109
Use libkiwix to store bookmarks
2024-02-07 11:02:02 +01:00
MohitMaliFtechiz
81994805b7 Upgraded java-libkiwix to 2.0.0
* Re-enabled test case for migrating bookmarks more then 512 to test it properly on API level 24.
2024-02-07 11:44:56 +05:30
MohitMaliFtechiz
1460e0d4e5 Fixed Migration test was failing on the API level 24. 2024-02-07 11:44:28 +05:30
MohitMaliFtechiz
ed2a9e0ec9 Fixed the failing LibkiwixBookmarkTest on Android 33 and 30. 2024-02-07 11:44:16 +05:30
MohitMaliFtechiz
50f92beeb1 Fixed the failing LibkiwixBookmarkTest.
* Enhanced the process of adding books to the library to prevent unnecessary data loading from libkiwix.
* Released the memory occupied by bookmarks and archives to resolve potential issues when running migrations on lower-end devices.
2024-02-07 11:44:08 +05:30
MohitMaliFtechiz
99cf75bf59 Improved the large data migration.
* Refined test cases to thoroughly assess the migration process.
* Enhanced the migration logic to effectively manage large datasets during migration.
* Optimized the Bookmark functionality to minimize unnecessary data loading on libkiwix. Retrieving data from libkiwix is now performed only when there is a change in the bookmark, reducing redundant data fetches. Otherwise, the previously loaded data is returned to minimize unnecessary resource access.
2024-02-07 11:44:00 +05:30
MohitMaliFtechiz
efd8caf244 Enhanced the migration process to handle exceptions more effectively. 2024-02-07 11:43:47 +05:30
MohitMaliFtechiz
f45e321655 Refactored the test cases.
* Improved the instrumentation test cases.
* Improved the migration test case.
2024-02-07 11:43:37 +05:30
MohitMaliFtechiz
e866dd29b5 Writing bookmarks and library data to a file in the background to avoid impacting application performance. 2024-02-07 11:43:26 +05:30
MohitMali
60966b9a52 Getting zimFilePath efficiently for LibkiwixBookmarkItem.
* Removed unused imports.
2024-02-07 11:42:43 +05:30
MohitMali
8666675acc Storing bookmarks/library inside our app-specific directory 2024-02-07 11:35:41 +05:30
MohitMali
ecc0d4b484 Removed unnecessary comments 2024-02-07 11:35:32 +05:30
MohitMali
0d48e23da5 Instead of creating an archive object for every book and retrieving the favicon from it, we are now speeding up the process by directly taking the favicon from the book, as the issue at https://github.com/kiwix/java-libkiwix/issues/73 has been resolved. 2024-02-07 11:35:21 +05:30
MohitMali
d821d5a07b Fixed path and improved the logs 2024-02-07 11:35:13 +05:30
MohitMali
aaa9cc368c Added logs while reading reading the bookmarks/library data, and added logs before writing the library in file. 2024-02-07 11:35:06 +05:30
MohitMali
6c5afa9413 The writing of the library to a file when retrieving bookmarks for the current book has been removed because adding the book to the library is unnecessary, as we have not saved any bookmarks yet.
* We now write bookmarks and the library on the main thread instead of saving them in the background thread to prevent any data loss.
2024-02-07 11:34:57 +05:30
MohitMali
1f3cfd6739 Fixed, compilation error 2024-02-07 11:34:49 +05:30
MohitMali
a3af901ef6 Resolved bookmark saving issue, which causes the bug when we try to retrieve the saved bookmarks.
* 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.
2024-02-07 11:34:41 +05:30
MohitMali
a78c4562f2 Removed the unnecessary wrapper classes of libkiwix from the codebase since we don't need these classes as saving/deleting functionality will be tested in java-libkiwix.
* Added instrumentation test case for testing the UI part with libkiwix bookmark functionality.
2024-02-07 11:34:33 +05:30
MohitMaliFtechiz
94a529cdf9 Introducing the writeFile method of the Library class allows us to save the library, which contains information about books, their file paths, and favicons, into a file.
* 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.
2024-02-07 11:34:21 +05:30
MohitMali
07e40ee3ac Improved LibkiwixBookTest and added new ObjectBoxToLibkiwixMigratorTest cases 2024-02-07 11:33:34 +05:30
MohitMali
3d7a4af7d3 Fixed application crash while running application on the emulators. 2024-02-07 11:33:27 +05:30