Commit 06b46218 authored by Qiu Xiang's avatar Qiu Xiang

修正 iOS marker 事件接口

parent 7c8a11b9
import React, {PropTypes, Component} from 'react'
import {requireNativeComponent, View, PixelRatio} from 'react-native'
import {requireNativeComponent, View, PixelRatio, Platform} from 'react-native'
import {LatLng} from './PropTypes'
import InfoWindow from './InfoWindow'
......@@ -100,11 +100,15 @@ class Marker extends Component {
render() {
const props = {
...this.props,
onMarkerClick: this._handle('onPress'),
onMarkerDragStart: this._handle('onDragStart'),
onMarkerDrag: this._handle('onDrag'),
onMarkerDragEnd: this._handle('onDragEnd'),
onInfoWindowClick: this._handle('onInfoWindowPress'),
...Platform.select({
android: {
onMarkerClick: this._handle('onPress'),
onMarkerDragStart: this._handle('onDragStart'),
onMarkerDrag: this._handle('onDrag'),
onMarkerDragEnd: this._handle('onDragEnd'),
onInfoWindowClick: this._handle('onInfoWindowPress'),
},
})
}
let customInfoWindow = null
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment