private CefRegistration(cef_registration_t *ptr) { if (ptr == null) { throw new ArgumentNullException("ptr"); } _self = ptr; }
internal static CefRegistration FromNativeOrNull(cef_registration_t *ptr) { if (ptr == null) { return(null); } return(new CefRegistration(ptr)); }
public void Dispose() { if (_self != null) { Release(); _self = null; } GC.SuppressFinalize(this); }
public static int has_one_ref(cef_registration_t *self) { has_one_ref_delegate d; var p = self->_base._has_one_ref; if (p == _p2) { d = _d2; } else { d = (has_one_ref_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(has_one_ref_delegate)); if (_p2 == IntPtr.Zero) { _d2 = d; _p2 = p; } } return(d(self)); }
public static int release(cef_registration_t *self) { release_delegate d; var p = self->_base._release; if (p == _p1) { d = _d1; } else { d = (release_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(release_delegate)); if (_p1 == IntPtr.Zero) { _d1 = d; _p1 = p; } } return(d(self)); }
public static void add_ref(cef_registration_t *self) { add_ref_delegate d; var p = self->_base._add_ref; if (p == _p0) { d = _d0; } else { d = (add_ref_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(add_ref_delegate)); if (_p0 == IntPtr.Zero) { _d0 = d; _p0 = p; } } d(self); }
public CefRegistration(cef_registration_t *instance) : base((cef_base_ref_counted_t *)instance) { }
internal static CefRegistration FromNative(cef_registration_t *ptr) { return(new CefRegistration(ptr)); }