390 Commits

Author SHA1 Message Date
MohitMaliFtechiz
2423b6b683 * Fixed: Made a small improvement to the sidebar entries for "About the app" and "Support app."
* Introduced the 'Support kiwix' option, which is configurable in the navigation for custom apps. If the custom app is set to display the "Support" menu item in navigation, it will be shown; otherwise, it will be hidden from the app.
* Replaced the "kiwix" and "the" prefixes in "Support kiwix" and "About the app" with the app name in the navigation.
2023-12-15 16:44:25 +05:30
MohitMaliFtechiz
25eab4e5fb Introduced the 'About the app' option in the navigation for custom apps.
* If the custom app is configured to display the 'About the app' option in navigation, it will be visible. Clicking on it will redirect the user to the configured URL.
2023-12-14 12:44:05 +05:30
MohitMaliFtechiz
3ca6a15058 Fixes the issue where the "Help" submenu in the sidebar is misleading in custom apps.
* We have hidden the help screen from our sidebar.
2023-12-14 07:45:15 +01:00
MohitMaliFtechiz
caf776a60d Introduced the disable external links option for custom apps.
* We have introduced the option to disable external links for custom apps. If a custom app is configured not to display the external links popup, it will both hide the external links preference from settings and refrain from showing the external link popup when opening external links. Additionally, we have included relevant comments within the methods and code to provide developers with a clear understanding of the reasons behind these changes.
2023-12-14 07:43:25 +01:00
MohitMaliFtechiz
e391b407b2 Fixed the left margin on the placeholder to make it look nice on the phone. 2023-12-06 17:05:43 +05:30
MohitMaliFtechiz
bbcf8bea8c Added a placeholder for search in custom apps.
* Introduced a search placeholder for custom apps; if any custom app is configured not to show the title in the toolbar, it will display the search placeholder with a border. To implement this change, a layout has been added inside the toolbar.
* To enhance understanding of this change, proper comments have been added to the methods.
2023-12-06 16:00:35 +05:30
MohitMaliFtechiz
88475d8601 The app icon will no longer automatically be replaced with three lines after closing the tabs screen in custom apps when the custom app is configured not to show the title. 2023-12-06 16:00:28 +05:30
MohitMaliFtechiz
2c1c678819 Fixed code formatting issue. 2023-12-06 16:00:22 +05:30
MohitMaliFtechiz
cd7b988fe1 Adjusted the size of the hamburger icon. * To address unexpected behavior, where setting the icon directly to the hamburger resulted in it taking the full width and height of the toolbar, we resized the app icon and applied it to the hamburger icon. 2023-12-06 16:00:15 +05:30
MohitMaliFtechiz
f46f2f324b Introduced the disable title option for custom apps. 2023-12-06 16:00:07 +05:30
translatewiki.net
e2585529d2 Localisation updates from https://translatewiki.net. 2023-12-01 21:05:15 +01:00
MohitMaliFtechiz
68f811bd2c Fixed the issue by correctly setting up the bookmark disposable for the current ZIM file in custom apps when opening bookmarks for the currently opened book. 2023-11-22 11:32:18 +05:30
MohitMali
b75221959c Added comments to CustomReaderFragment to explain why we have overridden these methods and describe their functionality. 2023-11-16 19:10:26 +05:30
MohitMali
748f0c4d5f Moved openSearchItem, findInPage functionality to our CoreReaderFragment as we were using same code twice for these methods in app and custom module. 2023-11-16 19:10:02 +05:30
MohitMali
e0c4b453bd Removed unnecessary overriding of onBackPressed method. 2023-11-16 18:59:05 +05:30
MohitMali
132f376243 Fixed, Hitting back on the DWDS app exits it.
* We removed the activity finishing triggered by pressing the back button in the reader fragment. We initially added this when we were converting CustomReader to a fragment, as we encountered crashing issues at the time. However, it was quite some time ago, and we have since refactored our code. Now, it no longer crashes and functions smoothly without terminating the activity when the back button is pressed. We also made this change for when a user presses the back button from the download screen. This back button press is within the CustomReaderFragment, so it does not impact the functionality of the DownloadFragment.
2023-11-16 18:58:58 +05:30
MohitMali
8b1cb8bc7e We are temporary hiding the kiwixServer feature from Custom Apps.
* 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.
2023-11-12 18:06:05 +01:00
MohitMali
bdb00d7aae Fixed the issue where the Zim File was not displaying in the ZimHostFragment for custom apps.
* 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`.
2023-11-12 18:06:05 +01:00
MohitMali
f31535966b Using AssetFileDescriptor instead of ParcelFileDescriptor. 2023-11-12 18:06:05 +01:00
MohitMali
c8b98cc504 Using ParcelFileDescriptor instead of FileDescriptor.
* Telling android to not compress the `.zim` files in asset folder while building the apk/bundle.
2023-11-12 18:06:05 +01:00
MohitMali
99614ed88f Introducing reading zim file content through fileDescriptor instead of creating a file to avoid using storage twice for same zim file. 2023-11-12 18:06:05 +01:00
MohitMali
0b59d9c586 Fixed, the DWDS app is very slow when opening a search result.
* Now, `libkiwix` provides the `pageUrl` along with the `pageTitle` (searchTitle). Previously, we were not using this `pageUrl` provided by `libkiwix`. Instead, we were making another request for the `pageUrl` based on the `pageTitle`, which was slowing down the process. We have now started directly using the `pageUrl` provided by `libkiwix` during the search. This change has made the process much more efficient and faster.
* To ensure the previously saved searches still work as expected, we have implemented a condition.
* We have added a new column in RecentSearchEntity for saving the `pageUrl` that we will use when user clicks on the recentSearchHistory.
2023-10-31 13:29:36 +01:00
translatewiki.net
bf089fdea0 Localisation updates from https://translatewiki.net. 2023-10-30 13:09:52 +01:00
Gouri Panda
a2f2bee81f Updated the asset folder naming 2023-10-21 13:15:59 +05:30
MohitMali
338d64efa7 Refactored the code to make the 'Play Asset Delivery' process generic.
* Renamed the module to 'install_time_asset' to make it generic for every custom app.
2023-10-20 16:16:34 +05:30
MohitMali
724f4a7ff4 Enhanced zim file loading functionality.
* We have corrected the order of obtaining ZIM files, specifically for the DWDS application. In this application, we retrieve the ZIM file from the asset folder, and there is no ZIM file inside the obb/files directory. This adjustment addresses an issue where a temporary file was mistakenly added to the files directory, causing the application to return an invalid file. By changing this order, it does not impact previous apps, as they do not have the ZIM file in the asset folder, allowing them to skip this part and function normally.
2023-10-20 14:41:35 +05:30
MohitMali
69ce81c175 Enhanced asset loading.
* Assets were always copied, even if they were already present in storage. This resulted in slow startup times, as the files were copied on each run. We now only write assets to a file when no file exists or corrupted.
2023-10-20 12:32:56 +05:30
Gouri Panda
e32ba6d70b Bundle order issue fixed 2023-10-20 02:03:51 +05:30
MohitMali
1d39d35d98 Added build task to sync the changes.
* In our 'publishingBundle' task, we are sequentially executing the 'downloading' and 'buildingBundle' tasks. Since we dynamically download and place the ZIM file, Gradle does not initially recognize any new files added to the asset folder. As a result, these files are not included in our bundle. Now, after downloading and placing the ZIM file in the asset folder, we synchronize our changes, allowing Gradle to detect the addition of new files.
2023-10-19 16:03:56 +05:30
MohitMali
725a5ccd0b Added overrided version code suffix 2023-10-17 15:36:10 +05:30
MohitMali
53d4ac1847 Fixed version code not found exception while publishing bundle on play store 2023-10-17 15:13:09 +05:30
MohitMali
1b87900695 Fixed zim file not found when we try to retrieve it from Play asset delivery to our application.
* We are now storing the zim file name in buildConfig file which we will use when we try to retrieve it later.
* Improved downloading functionality.
2023-10-17 12:28:42 +05:30
MohitMali
4c951de69e Fixed, Unable to upload APK on play store for new apps.
* We have implemented Play Asset Delivery to include the ZIM file within the Android App Bundle (AAB).
* To achieve this, we've created Gradle tasks to automatically download the ZIM file and place it inside the assets folder.
* In order to utilize this asset file, we've refactored our custom application code.
* We haven't removed the functionality of uploading the APK, as this approach remains static for now. Thus, we are retaining both codebases.
2023-10-17 11:07:45 +05:30
MohitMali
7460b9d6e5 Fixed, Code formatting issue 2023-10-16 12:58:59 +05:30
Gouri Panda
c4405ab6d1 Fixed language bundle issue for the playstore 2023-10-14 12:48:02 +02:00
Gouri Panda
12c6f5ec79 Reverting fixed language bundle issue for the playstore 2023-10-14 12:48:02 +02:00
Gouri Panda
033d11679e Fixed language bundle issue for the playstore 2023-10-14 12:48:02 +02:00
MohitMali
8c9cdcb6c6 Disabled the universal APK as now we are uploading the dummy bundle for custom apps instead of APK. 2023-10-14 12:48:02 +02:00
MohitMali
8f0d3fff2c We have enabled the universal APK for custom apps because we require this universal APK to create dummy APKs for the Play Store. 2023-10-14 12:48:02 +02:00
MohitMali
11c5b3caa2 Fixed URLConnection not adding headers to the request.
* In this update, we've replaced the `URLConnection` with the OkHttp library, and now headers are being correctly passed in the request. As a result, the Zim file is successfully downloading.
* To integrate OkHttp into our Gradle project, we've moved the OkHttp dependency to our `buildSrc` folder.
2023-10-14 12:48:02 +02:00
MohitMali
41be43d292 Fixed ZimHostFragment Open Issue for Both App and Custom Modules.
* We moved our server functionality to the core module to enable its use in both our app and custom modules. However, this change posed a challenge. We had a functionality that, when the user clicks on a notification, it takes them to the hosted book screen. By moving this functionality to the core module, we lost direct access to the navigation graph and `KiwixMainActivity` or `CustomMainActivity`.
* To address this issue, we introduced some abstract variables, such as navGraphId and mainActivity, which we set from both `KiwixMainActivity` and `CustomMainActivity`. This allows us to retrieve the navigation graph ID and the main activity.
* Additionally, we implemented a new function in `CoreApp` to set the currently running `CoreMainActivity`, which we use to obtain the navigation graph ID and main activity to perform the user click on notification.
2023-10-14 09:59:39 +02:00
MohitMali
94d592f545 Reintroduce wifi hotspot feature in custom apps.
* Moved wifi hotspot related files to core module to use hotspot functionality in both app and custom module.
* Moved permission in core manifest to access them in both modules.
* Removed some unnecessary files which is now no longer in use.
2023-10-14 09:59:39 +02:00
Gouri Panda
cdd4ce7fae Revert checking the authentication if works 2023-10-08 02:02:35 +05:30
Gouri Panda
0b4b223692 checking the authentication if works 2023-10-08 01:53:14 +05:30
Gouri Panda
852deaf57b changed order of chain request 2023-10-08 01:14:08 +05:30
Gouri Panda
717d593ad3 Fixed the bug that was happening in the ci 2023-10-07 20:05:50 +05:30
MohitMali
77f5146d64 Fixed CustomDownloadViewModelTest 2023-10-04 19:17:12 +02:00
MohitMali
e4624b238b Handled download on the first run when no ZIM file is found.
* We are showing a custom error message to the user for this type authentication urls because we does not have any authentication values in our application so it will always fail to download the zim file, so we are showing a error message where we inform to user to reinstall application from the playstore. Since play store application have the zim file in it.
2023-10-04 19:17:12 +02:00
MohitMali
f7517a2272 Minimum SDK version changed to 24: The NDK version in kiwix-build has been upgraded (as mentioned in https://github.com/kiwix/kiwix-build/issues/544). However, to make this upgrade compatible, the minimum SDK version had to be updated to 24 since the NDK version is not compatible with Android API levels below 24. The README.md file has been updated to reflect the new minimum Android support version, which is now Android 7, due to the change in the minimum SDK version. Since the project's minimum SDK version is now 24, some conditions related to Android 23 and 24 have become unused. These unused conditions have been removed, and along with that, the drawable-night-23 and drawable-23 launch_screen.xml files, which were no longer in use, have also been removed. 2023-09-18 19:13:20 +02:00
translatewiki.net
f29c206729 Localisation updates from https://translatewiki.net. 2023-09-18 13:08:06 +02:00