package com.hiringhall.map import android.content.Context import com.facebook.react.bridge.ReactContext import com.facebook.react.uimanager.ThemedReactContext import com.google.android.gms.maps.MapView import com.google.android.gms.maps.OnMapReadyCallback import kotlin.properties.ReadOnlyProperty import kotlin.reflect.KProperty /** * Created by saionara1 on 8/1/17. */ class MapDelegate(val context: ThemedReactContext?, val callback: OnMapReadyCallback) : ReadOnlyProperty { override fun getValue(thisRef: Nothing?, property: KProperty<*>): MapView { val mapView = MapView(context) mapView.onCreate(null); mapView.onResume() mapView.getMapAsync(callback) return mapView; } }