docs: add v2 route deep link example#16
Closed
Komzpa wants to merge 3 commits into
Closed
Conversation
- sample-app-capitals: add missing startActivity() in onActivityResult and setPickPointMode(true) on outgoing MapRequests so OM actually returns the picked point; null-guard the result flow; make EXTRA_POINT final. - PickPointResponse.extractFromIntent: null-guard intent.getExtras() and declare @NonNull/@nullable. - OrganicMapsApi: Allman braces, drop extraneous ;, add app.organicmaps.web flavour to isOrganicMapsPackageInstalled. - Bump gradle wrapper to 9.4.1 to match AGP 9.2.1. - .gitignore: block reintroduction of the Eclipse-era module-root layout (/*/AndroidManifest.xml, /*/build.xml, /*/project.properties, /*/res/, /*/src/com/) and widen .idea to all modules. - Delete the legacy lib/{AndroidManifest,build.xml,project.properties, res,src/com} and sample-app-capitals/{same,...,.idea} trees. - README: full rewrite around the real OrganicMapsApi + ActivityResultLauncher flow, document both samples. - CLAUDE.md: update build numbers and source-layout note. Signed-off-by: Alexander Borsuk <me@alex.bio>
Mirror each Java snippet (showPointsOnMap, ActivityResult round-trip, CrosshairRequest) with an idiomatic Kotlin version. Call out that Java getters surface as Kotlin properties (response.point, point.id, response.zoomLevel) and that mapTo(ArrayList()) is needed because showPointsOnMap takes ArrayList<Point>, not List<Point>. Signed-off-by: Alexander Borsuk <me@alex.bio>
Signed-off-by: Darafei Praliaskouski <me@komzpa.net> (cherry picked from commit 5ed4755)
8be4501 to
8f853e0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Adds Java and Kotlin README examples for opening Organic Maps v2 route deep links directly from an app, matching the route-deeplink documentation pattern used by the API repos.\n\nThis is intended as a helper PR for #15.\n\nValidation:\n-
git diff --check origin/pr/15..HEAD\n-JAVA_HOME=/usr/lib/jvm/java-21-openjdk-amd64 ANDROID_HOME=/usr/lib/android-sdk ANDROID_SDK_ROOT=/usr/lib/android-sdk ./gradlew assemble