Skip to content

Commit

Permalink
Merge pull request #397 from fgutteridge/master
Browse files Browse the repository at this point in the history
feat(all): add markerInfoWindowClosed event
  • Loading branch information
dapriett authored Jan 8, 2020
2 parents 30c692e + a1de6b2 commit 8e5b605
Show file tree
Hide file tree
Showing 13 changed files with 4,094 additions and 365 deletions.
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,19 +158,20 @@ The following events are available:
| Event | Description
:------------- | :---------------------------------
`mapReady` | Fires when the MapView is ready for use
`myLocationTapped` | Fires when the 'My Location' button is tapped
`coordinateTapped` | Fires when a coordinate is tapped on the map
`coordinateLongPress` | Fires when a coordinate is long-pressed on the map
`markerSelect` | Fires when a marker is selected
`shapeSelect` | Fires when a shape (e.g., `Circle`, `Polygon`, `Polyline`) is selected *(Note: you must explicity configure `shape.clickable = true;` for this event to fire)*
`markerBeginDragging` | Fires when a marker begins dragging
`markerEndDragging` | Fires when a marker ends dragging
`markerDrag` | Fires repeatedly while a marker is being dragged
`myLocationTapped` | Fires when the 'My Location' button is tapped
`markerInfoWindowTapped` | Fires when a marker's info window is tapped
`markerInfoWindowClosed` | Fires when a marker's info window is closed
`shapeSelect` | Fires when a shape (e.g., `Circle`, `Polygon`, `Polyline`) is selected *(Note: you must explicity configure `shape.clickable = true;` for this event to fire)*
`cameraChanged` | Fires after the camera has changed
`cameraMove` | Fires repeatedly while the camera is moving
`indoorBuildingFocused` | Fired when the focused building (building currently centered, selected by user or by location provider)
`indoorLevelActivated` | Fired when the level of the focused building change
`indoorBuildingFocused` | Fires when a building is focused on (the building currently centered, selected by the user or by the location provider)
`indoorLevelActivated` | Fires when the level of the focused building changes

## Native Map Object

Expand Down
26 changes: 16 additions & 10 deletions demo/app/main-page.xml
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
<Page xmlns="http://www.nativescript.org/tns.xsd" xmlns:maps="nativescript-google-maps-sdk" loaded="pageLoaded">
<GridLayout>
<maps:mapView latitude="{{ latitude }}" longitude="{{ longitude }}"
zoom="{{ zoom }}" minZoom="{{ minZoom }}" maxZoom="{{ maxZoom }}" bearing="{{ bearing }}" mapAnimationsEnabled="{{ mapAnimationsEnabled }}"
tilt="{{ tilt }}" i-padding="50,50,50,50" padding="{{ padding }}" mapReady="onMapReady"
markerSelect="onMarkerEvent" markerBeginDragging="onMarkerEvent"
markerEndDragging="onMarkerEvent" markerDrag="onMarkerEvent"
markerInfoWindowTapped="onMarkerEvent" coordinateTapped="onCoordinateTapped"
cameraChanged="onCameraChanged"
indoorBuildingFocused="onIndoorBuildingFocused"
indoorLevelActivated="onIndoorLevelActivated"
cameraMove="onCameraMove">
<maps:mapView
latitude="{{ latitude }}" longitude="{{ longitude }}"
zoom="{{ zoom }}" minZoom="{{ minZoom }}" maxZoom="{{ maxZoom }}"
tilt="{{ tilt }}" bearing="{{ bearing }}"
mapAnimationsEnabled="{{ mapAnimationsEnabled }}"
i-padding="50,50,50,50" padding="{{ padding }}"
mapReady="onMapReady"
coordinateTapped="onCoordinateTapped"
markerSelect="onMarkerEvent"
markerBeginDragging="onMarkerEvent" markerEndDragging="onMarkerEvent" markerDrag="onMarkerEvent"
markerInfoWindowTapped="onMarkerEvent" markerInfoWindowClosed="onMarkerEvent"
cameraChanged="onCameraChanged"
cameraMove="onCameraMove"
indoorBuildingFocused="onIndoorBuildingFocused"
indoorLevelActivated="onIndoorLevelActivated"
>
<maps:mapView.infoWindowTemplate>
<StackLayout orientation="vertical" width="200" height="150" >
<Label text="{{title}}" className="title" width="125" />
Expand Down
3 changes: 2 additions & 1 deletion demo/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
},
"homepage": "https://github.com/NativeScript/template-hello-world",
"android": {
"v8Flags": "--expose_gc"
"v8Flags": "--expose_gc",
"markingMode": "none"
}
}
Loading

0 comments on commit 8e5b605

Please sign in to comment.