Beispiel #1
0
        /// <summary>
        /// Called when the Favicon URL for a page changes.
        /// </summary>
        private void on_favicon_urlchange(cef_display_handler_t *self, cef_browser_t *browser, cef_string_list *icon_urls)
        {
            ThrowIfObjectDisposed();

            var m_browser   = CefBrowser.From(browser);
            var m_icon_urls = CefStringList.From(icon_urls);

            this.OnFaviconChange(m_browser, m_icon_urls);
        }
Beispiel #2
0
        /// <summary>
        /// Retrieve the list of file names that are being dragged into the
        /// browser window.
        /// </summary>
        public CefStringList GetFileNames()
        {
            var nList = CefStringList.CreateHandle();

            var success = cef_drag_data_t.invoke_get_file_names(this.ptr, nList) != 0;

            if (success)
            {
                return(CefStringList.From(nList, true));
            }
            else
            {
                CefStringList.DestroyHandle(nList);
                return(null);
            }
        }
Beispiel #3
0
        /// <summary>
        /// Read the keys for the object's values into the specified vector.
        /// Integer- based keys will also be returned as strings.
        /// </summary>
        public bool TryGetKeys(out CefStringList keys)
        {
            ThrowIfObjectIsInvalid();
            var nList = CefStringList.CreateHandle();

            var success = cef_v8value_t.invoke_get_keys(this.ptr, nList) != 0;

            if (success)
            {
                keys = CefStringList.From(nList, true);
                return(true);
            }
            else
            {
                CefStringList.DestroyHandle(nList);
                keys = null;
                return(false);
            }
        }