private static void Microsoft_Kinect_VisualGestureBuilder_TrackingIdLostEventArgs_Delegate_Handler(RootSystem.IntPtr result, RootSystem.IntPtr pNative)
        {
            List <RootSystem.EventHandler <Microsoft.Kinect.VisualGestureBuilder.TrackingIdLostEventArgs> > callbackList = null;

            Microsoft_Kinect_VisualGestureBuilder_TrackingIdLostEventArgs_Delegate_callbacks.TryGetValue(pNative, out callbackList);
            lock (callbackList)
            {
                var objThis = Helper.NativeObjectCache.GetObject <VisualGestureBuilderFrameSource>(pNative);
                var args    = new Microsoft.Kinect.VisualGestureBuilder.TrackingIdLostEventArgs(result);
                foreach (var func in callbackList)
                {
                    Helper.EventPump.Instance.Enqueue(() => { try { func(objThis, args); } catch { } });
                }
            }
        }
 private static void Microsoft_Kinect_VisualGestureBuilder_TrackingIdLostEventArgs_Delegate_Handler(RootSystem.IntPtr result, RootSystem.IntPtr pNative)
 {
     List<RootSystem.EventHandler<Microsoft.Kinect.VisualGestureBuilder.TrackingIdLostEventArgs>> callbackList = null;
     Microsoft_Kinect_VisualGestureBuilder_TrackingIdLostEventArgs_Delegate_callbacks.TryGetValue(pNative, out callbackList);
     lock(callbackList)
     {
         var objThis = Helper.NativeObjectCache.GetObject<VisualGestureBuilderFrameSource>(pNative);
         var args = new Microsoft.Kinect.VisualGestureBuilder.TrackingIdLostEventArgs(result);
         foreach(var func in callbackList)
         {
             Helper.EventPump.Instance.Enqueue(() => { try { func(objThis, args); } catch { } });
         }
     }
 }