Ejemplo n.º 1
0
 internal static HandleRef getCPtr(XPressoTag obj) {
   return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
 }
Ejemplo n.º 2
0
  public static BaseTag InstantiateConcreteObject(IntPtr cPtr, bool owner)
  {
    BaseTag ret = null;
    if (cPtr == IntPtr.Zero) 
	{
      return ret;
    }
    int type = C4dApiPINVOKE.C4DAtom_GetType(new HandleRef(null, cPtr));
    switch (type) 
	{
       case 0:
         ret = new BaseTag(cPtr, owner);
         break;
       case 1001149:
         ret = new XPressoTag(cPtr, owner);
         break;
      // Repeat for every other concrete type.
      default:
	  //changed from the debug output to return a BaseTag object
        ret = new BaseTag(cPtr, owner);
        break;
    }
    return ret;
  }