Пример #1
0
        private void visit(cef_domvisitor_t* self, cef_domdocument_t* document)
        {
            CheckSelf(self);

            var m_document = CefDomDocument.FromNative(document);

            Visit(m_document);

            m_document.Dispose();
        }
Пример #2
0
 internal static CefDomDocument FromNative(cef_domdocument_t* ptr)
 {
     return new CefDomDocument(ptr);
 }
 public static cef_string_userfree* get_base_url(cef_domdocument_t* self)
 {
     get_base_url_delegate d;
     var p = self->_get_base_url;
     if (p == _p11) { d = _d11; }
     else
     {
         d = (get_base_url_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_base_url_delegate));
         if (_p11 == IntPtr.Zero) { _d11 = d; _p11 = p; }
     }
     return d(self);
 }
 public static cef_string_userfree* get_complete_url(cef_domdocument_t* self, cef_string_t* partialURL)
 {
     get_complete_url_delegate d;
     var p = self->_get_complete_url;
     if (p == _p12) { d = _d12; }
     else
     {
         d = (get_complete_url_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_complete_url_delegate));
         if (_p12 == IntPtr.Zero) { _d12 = d; _p12 = p; }
     }
     return d(self, partialURL);
 }
 public static int get_selection_end_offset(cef_domdocument_t* self)
 {
     get_selection_end_offset_delegate d;
     var p = self->_get_selection_end_offset;
     if (p == _pe) { d = _de; }
     else
     {
         d = (get_selection_end_offset_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_selection_end_offset_delegate));
         if (_pe == IntPtr.Zero) { _de = d; _pe = p; }
     }
     return d(self);
 }
 public static cef_string_userfree* get_selection_as_text(cef_domdocument_t* self)
 {
     get_selection_as_text_delegate d;
     var p = self->_get_selection_as_text;
     if (p == _p10) { d = _d10; }
     else
     {
         d = (get_selection_as_text_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_selection_as_text_delegate));
         if (_p10 == IntPtr.Zero) { _d10 = d; _p10 = p; }
     }
     return d(self);
 }
 public static int has_selection(cef_domdocument_t* self)
 {
     has_selection_delegate d;
     var p = self->_has_selection;
     if (p == _pa) { d = _da; }
     else
     {
         d = (has_selection_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(has_selection_delegate));
         if (_pa == IntPtr.Zero) { _da = d; _pa = p; }
     }
     return d(self);
 }
 public static int release(cef_domdocument_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 cef_string_userfree* get_title(cef_domdocument_t* self)
 {
     get_title_delegate d;
     var p = self->_get_title;
     if (p == _p7) { d = _d7; }
     else
     {
         d = (get_title_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_title_delegate));
         if (_p7 == IntPtr.Zero) { _d7 = d; _p7 = p; }
     }
     return d(self);
 }
 public static cef_domnode_t* get_element_by_id(cef_domdocument_t* self, cef_string_t* id)
 {
     get_element_by_id_delegate d;
     var p = self->_get_element_by_id;
     if (p == _p8) { d = _d8; }
     else
     {
         d = (get_element_by_id_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_element_by_id_delegate));
         if (_p8 == IntPtr.Zero) { _d8 = d; _p8 = p; }
     }
     return d(self, id);
 }
 public static cef_domnode_t* get_head(cef_domdocument_t* self)
 {
     get_head_delegate d;
     var p = self->_get_head;
     if (p == _p6) { d = _d6; }
     else
     {
         d = (get_head_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_head_delegate));
         if (_p6 == IntPtr.Zero) { _d6 = d; _p6 = p; }
     }
     return d(self);
 }
 public static CefDomDocumentType get_type(cef_domdocument_t* self)
 {
     get_type_delegate d;
     var p = self->_get_type;
     if (p == _p3) { d = _d3; }
     else
     {
         d = (get_type_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_type_delegate));
         if (_p3 == IntPtr.Zero) { _d3 = d; _p3 = p; }
     }
     return d(self);
 }
 public static int get_refct(cef_domdocument_t* self)
 {
     get_refct_delegate d;
     var p = self->_base._get_refct;
     if (p == _p2) { d = _d2; }
     else
     {
         d = (get_refct_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_refct_delegate));
         if (_p2 == IntPtr.Zero) { _d2 = d; _p2 = p; }
     }
     return d(self);
 }
Пример #14
0
 internal static CefDomDocument FromNativeOrNull(cef_domdocument_t* ptr)
 {
     if (ptr == null) return null;
     return new CefDomDocument(ptr);
 }
 public static cef_domnode_t* get_selection_end_node(cef_domdocument_t* self)
 {
     get_selection_end_node_delegate d;
     var p = self->_get_selection_end_node;
     if (p == _pd) { d = _dd; }
     else
     {
         d = (get_selection_end_node_delegate)Marshal.GetDelegateForFunctionPointer(p, typeof(get_selection_end_node_delegate));
         if (_pd == IntPtr.Zero) { _dd = d; _pd = p; }
     }
     return d(self);
 }
Пример #16
0
 private CefDomDocument(cef_domdocument_t* ptr)
 {
     if (ptr == null) throw new ArgumentNullException("ptr");
     _self = ptr;
 }
 public static int add_ref(cef_domdocument_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; }
     }
     return d(self);
 }