internal static cef_completion_callback_t* Alloc()
 {
     var ptr = (cef_completion_callback_t*)Marshal.AllocHGlobal(_sizeof);
     *ptr = new cef_completion_callback_t();
     ptr->_base._size = (UIntPtr)_sizeof;
     return ptr;
 }
Example #2
0
        internal static cef_completion_callback_t *Alloc()
        {
            var ptr = (cef_completion_callback_t *)Marshal.AllocHGlobal(_sizeof);

            *ptr = new cef_completion_callback_t();
            ptr->_base._size = (UIntPtr)_sizeof;
            return(ptr);
        }
Example #3
0
 private void add_ref(cef_completion_callback_t* self)
 {
     lock (SyncRoot)
     {
         var result = ++_refct;
         if (result == 1)
         {
             lock (_roots) { _roots.Add((IntPtr)_self, this); }
         }
     }
 }
Example #4
0
 private int release(cef_completion_callback_t* self)
 {
     lock (SyncRoot)
     {
         var result = --_refct;
         if (result == 0)
         {
             lock (_roots) { _roots.Remove((IntPtr)_self); }
             return 1;
         }
         return 0;
     }
 }
Example #5
0
 public static extern int begin_tracing(cef_string_t* categories, cef_completion_callback_t* callback);
Example #6
0
 private void CheckSelf(cef_completion_callback_t* self)
 {
     if (_self != self) throw ExceptionBuilder.InvalidSelfReference();
 }
Example #7
0
 private int has_one_ref(cef_completion_callback_t* self)
 {
     lock (SyncRoot) { return _refct == 1 ? 1 : 0; }
 }
Example #8
0
        private void on_complete(cef_completion_callback_t* self)
        {
            CheckSelf(self);

            OnComplete();
        }
Example #9
0
 public static int flush_store(cef_cookie_manager_t* self, cef_completion_callback_t* callback)
 {
     flush_store_delegate d;
     var p = self->_flush_store;
     if (p == _p9) { d = _d9; }
     else
     {
         d = (flush_store_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(flush_store_delegate));
         if (_p9 == IntPtr.Zero) { _d9 = d; _p9 = p; }
     }
     return d(self, callback);
 }
 internal static void Free(cef_completion_callback_t* ptr)
 {
     Marshal.FreeHGlobal((IntPtr)ptr);
 }
Example #11
0
 private int get_refct(cef_completion_callback_t* self)
 {
     return _refct;
 }