+ Instance._controlMap.Add(refCptr, new WeakReference(view, false));
+ }
+
+ return;
+ }
+
+ /// <summary>
+ /// Remove the this instance of control (View) and native part from the mapping table.
+ /// </summary>
+ /// <param name="view"> The instance of control (View)</param>
+ public static void UnregisterView( View view )
+ {
+ RefObject refObj = view.GetObjectPtr();
+ IntPtr refCptr = (IntPtr) RefObject.getCPtr(refObj);
+
+ if ( Instance._controlMap.ContainsKey(refCptr) )
+ {
+ Instance._controlMap.Remove(refCptr);