Ejemplo n.º 1
0
        public static int belongs_to_thread(cef_task_runner_t *self, CefThreadId threadId)
        {
            belongs_to_thread_delegate d;
            var p = self->_belongs_to_thread;

            if (p == _p5)
            {
                d = _d5;
            }
            else
            {
                d = (belongs_to_thread_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(belongs_to_thread_delegate));
                if (_p5 == IntPtr.Zero)
                {
                    _d5 = d; _p5 = p;
                }
            }
            return(d(self, threadId));
        }
Ejemplo n.º 2
0
 public static int belongs_to_thread(cef_task_runner_t* self, CefThreadId threadId)
 {
     belongs_to_thread_delegate d;
     var p = self->_belongs_to_thread;
     if (p == _p5) { d = _d5; }
     else
     {
         d = (belongs_to_thread_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(belongs_to_thread_delegate));
         if (_p5 == IntPtr.Zero) { _d5 = d; _p5 = p; }
     }
     return d(self, threadId);
 }