-
Notifications
You must be signed in to change notification settings - Fork 493
Conversation
Copy+Paste from working repository
To support requestPointerCapture
Also sequence the map instance fetching
Questions for reviewersWhat kinds of tests do we typically add for examples?
What linter do you run locally (to avoid back-and-forth with circleci)? |
autoformat will be nice...
Hell of an example @sansumbrella . 👏 🎊 Made a commit that cleans up some small stuff; mainly moving string resource files to their correct locations. |
const val PERMISSION_REQUEST_LOCATION = 404 | ||
const val BASE_MAP_BUNDLE = "$TAG.basemap.bundle" | ||
const val REVEAL_MAP_BUNDLE = "$TAG.revealedMap.bundle" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add javadocs to explain what this example is about. E.g:
/**
* This example...
*/
const val TAG = "DragActivityTag" | ||
const val PERMISSION_REQUEST_LOCATION = 404 | ||
const val BASE_MAP_BUNDLE = "$TAG.basemap.bundle" | ||
const val REVEAL_MAP_BUNDLE = "$TAG.revealedMap.bundle" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For these const val
, please move them within the activity below the var initialZoom
line with
companion object {
const val TAG = "DragActivityTag"
const val PERMISSION_REQUEST_LOCATION = 404
const val BASE_MAP_BUNDLE = "$TAG.basemap.bundle"
const val REVEAL_MAP_BUNDLE = "$TAG.revealedMap.bundle"
}
const val BASE_MAP_BUNDLE = "$TAG.basemap.bundle" | ||
const val REVEAL_MAP_BUNDLE = "$TAG.revealedMap.bundle" | ||
|
||
class MagicWindowActivity : AppCompatActivity(), LocationEngineListener { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, let's go ahead and throw the word Kotlin
into the example's name. MagicWindowKotlinActivity
?
Not much. We run a test that makes sure that the example can be opened and doesn't crash:
We also do Firebase instrumentation tests
I'm not sure what the question/concern here is. A little clarification?
Yes, let's have Kotlin examples have the word
We don't? Don't think we do. Running |
Thanks for the feedback (and cleanup)! Getting on that now. My class organization question was just about whether we are happy to keep all code for one demo in a single file or if we want to have a single file per class. For demos, I think it makes sense to keep all the code in a single file as long as it isn't too big. I think other demos in this repo are organized that way.
This will do the trick. This sample just failed tests for a while since I wasn't running that locally. It would be cool if there were editor integration that auto-formatted to the right style a la gofmt or rustfmt. Maybe someday. |
Should be ready for another round of review and merging! Thanks. |
For now, let's do this. So keep things as is.
|
Adds magic window demo showing two maps kept in sync and alpha masking with the Android view system.
Closes #613