Codebase cleanup - fix build warnings, dependency errors, and compatibility with latest Android Studio #44
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi team,
Submitting a PR here in preparation for some upcoming features I'm planning to implement. I've started working on an accessibility service and enhanced MDM configurability.
A lot of what I'll be implementing extends on the wonderful work by @manfred-mueller in #40, but I wanted to submit an initial PR to tidy up a lot of the warnings and other deprications being thrown when building prior to making any significant changes.
While I have done my best to test the agent since these changes, I would love other contributors to provide feedback as I only have a limited fleet of test devices.
Key Changes
Modernized build tooling & dependencies
code-scanner,dexter,okhttp, Firebase libraries) to keep the project aligned with current Android tooling.Refined Kotlin code style and resources
varusages for immutable values, and deprecatedtoUpperCase()calls with Kotlin idioms and added_markers for unused lambda parameters.invalid_server_pairing_linkand centralizing thezero_stringresource (which might be a little overkill, but hey)fragment_auth.xmlconstraints to remove hard-coded layout ties which were throwing errors and instead used parent references (this is one thing that might require more testing/feedback).Addressed build warnings and deprecated APIs
MainActivityplus shared handling for pending file-deletion approvals (this is the most significant code change).MeshAgent/MeshTunnel, improved null safety for sockets, and ensured notifications useNotificationCompat.ScreenCaptureServiceto use safer handler/parcelable handling andNotificationUtilsto avoid deprecated notification fields.Additional runtime tweaks
nullresources and outdated APIs (vibrator, camera, encryption helpers).I welcome feedback from the team!