예제 #1
0
        public static void SetDelegate(ISN_iCLLocationManagerDelegate @delegate)
        {
#if API_ENABLED
            _ISN_CL_SetDelegate(
                ISN_MonoPCallback.ActionToIntPtr <int>(result =>
            {
                var auth = (ISN_CLAuthorizationStatus)result;
                @delegate.DidChangeAuthorizationStatus(auth);
            }),
                ISN_MonoPCallback.ActionToIntPtr <ISN_CLLocationArray>(result =>
            {
                @delegate.DidUpdateLocations(result);
            }),
                ISN_MonoPCallback.ActionToIntPtr <SA_Error>(result =>
            {
                @delegate.DidFailWithError(result);
            }),
                ISN_MonoPCallback.ActionToIntPtr <SA_Error>(result =>
            {
                @delegate.DidFinishDeferredUpdatesWithError(result);
            }),
                ISN_MonoPCallback.ActionToIntPtr <int>(result =>
            {
                @delegate.DidPauseLocationUpdates();
            }),
                ISN_MonoPCallback.ActionToIntPtr <int>(result =>
            {
                @delegate.DidResumeLocationUpdates();
            })
                );
#endif
        }