コード例 #1
0
ファイル: WebControl.cs プロジェクト: UIKit0/AwesomiumSharp
 private static extern void awe_webview_set_callback_dom_ready( IntPtr webview, CallbackDomReadyCallback callback );
コード例 #2
0
ファイル: WebControl.cs プロジェクト: UIKit0/AwesomiumSharp
        private void InitializeDelegates( IntPtr webview )
        {
            beginNavigationCallback = internalBeginNavigationCallback;
            awe_webview_set_callback_begin_navigation( webview, beginNavigationCallback );

            beginLoadingCallback = internalBeginLoadingCallback;
            awe_webview_set_callback_begin_loading( webview, beginLoadingCallback );

            finishLoadingCallback = internalFinishLoadingCallback;
            awe_webview_set_callback_finish_loading( webview, finishLoadingCallback );

            jsCallback = internalJsCallback;
            awe_webview_set_callback_js_callback( webview, jsCallback );

            receiveTitleCallback = internalReceiveTitleCallback;
            awe_webview_set_callback_receive_title( webview, receiveTitleCallback );

            changeTooltipCallback = internalChangeTooltipCallback;
            awe_webview_set_callback_change_tooltip( webview, changeTooltipCallback );

            changeCursorCallback = internalChangeCursorCallback;
            awe_webview_set_callback_change_cursor( webview, changeCursorCallback );

            changeKeyboardFocusCallback = internalChangeKeyboardFocusCallback;
            awe_webview_set_callback_change_keyboard_focus( webview, changeKeyboardFocusCallback );

            changeTargetURLCallback = internalChangeTargetURLCallback;
            awe_webview_set_callback_change_target_url( webview, changeTargetURLCallback );

            openExternalLinkCallback = internalOpenExternalLinkCallback;
            awe_webview_set_callback_open_external_link( webview, openExternalLinkCallback );

            requestDownloadCallback = internalRequestDownloadCallback;
            awe_webview_set_callback_request_download( webview, requestDownloadCallback );

            webviewCrashedCallback = internalWebviewCrashedCallback;
            awe_webview_set_callback_web_view_crashed( webview, webviewCrashedCallback );

            pluginCrashedCallback = internalPluginCrashedCallback;
            awe_webview_set_callback_plugin_crashed( webview, pluginCrashedCallback );

            requestMoveCallback = internalRequestMoveCallback;
            awe_webview_set_callback_request_move( webview, requestMoveCallback );

            getPageContentsCallback = internalGetPageContentsCallback;
            awe_webview_set_callback_get_page_contents( webview, getPageContentsCallback );

            domReadyCallback = internalDomReadyCallback;
            awe_webview_set_callback_dom_ready( webview, domReadyCallback );

            requestFileChooserCallback = internalRequestFileChooser;
            awe_webview_set_callback_request_file_chooser( webview, requestFileChooserCallback );

            getScrollDataCallback = internalGetScrollData;
            awe_webview_set_callback_get_scroll_data( webview, getScrollDataCallback );

            jsConsoleMessageCallback = internalJSConsoleMessage;
            awe_webview_set_callback_js_console_message( webview, jsConsoleMessageCallback );

            getFindResultsCallback = internalGetFindResults;
            awe_webview_set_callback_get_find_results( webview, getFindResultsCallback );

            updateIMECallback = internalUpdateIME;
            awe_webview_set_callback_update_ime( webview, updateIMECallback );

            resourceRequestCallback = internalResourceRequestCallback;
            awe_webview_set_callback_resource_request( webview, resourceRequestCallback );

            resourceResponseCallback = internalResourceResponseCallback;
            awe_webview_set_callback_resource_response( webview, resourceResponseCallback );

            if ( jsObjectCallbackMap == null )
                jsObjectCallbackMap = new Dictionary<string, JSCallback>();

            if ( this.JSCallbackCalled == null )
                this.JSCallbackCalled += handleJSCallback;

            selectionHelper.RegisterSelectionHelper();
        }
コード例 #3
0
ファイル: WebControl.cs プロジェクト: UIKit0/AwesomiumSharp
        private void ClearDelegates()
        {
            resourceRequestCallback = null;
            awe_webview_set_callback_resource_request( Instance, null );

            resourceResponseCallback = null;
            awe_webview_set_callback_resource_response( Instance, null );

            beginLoadingCallback = null;
            awe_webview_set_callback_begin_loading( Instance, null );

            beginNavigationCallback = null;
            awe_webview_set_callback_begin_navigation( Instance, null );

            changeCursorCallback = null;
            awe_webview_set_callback_change_cursor( Instance, null );

            changeKeyboardFocusCallback = null;
            awe_webview_set_callback_change_keyboard_focus( Instance, null );

            changeTargetURLCallback = null;
            awe_webview_set_callback_change_target_url( Instance, null );

            changeTooltipCallback = null;
            awe_webview_set_callback_change_tooltip( Instance, null );

            domReadyCallback = null;
            awe_webview_set_callback_dom_ready( Instance, null );

            finishLoadingCallback = null;
            awe_webview_set_callback_finish_loading( Instance, null );

            getFindResultsCallback = null;
            awe_webview_set_callback_get_find_results( Instance, null );

            getPageContentsCallback = null;
            awe_webview_set_callback_get_page_contents( Instance, null );

            getScrollDataCallback = null;
            awe_webview_set_callback_get_scroll_data( Instance, null );

            jsCallback = null;
            awe_webview_set_callback_js_callback( Instance, null );

            jsConsoleMessageCallback = null;
            awe_webview_set_callback_js_console_message( Instance, null );

            openExternalLinkCallback = null;
            awe_webview_set_callback_open_external_link( Instance, null );

            pluginCrashedCallback = null;
            awe_webview_set_callback_plugin_crashed( Instance, null );

            receiveTitleCallback = null;
            awe_webview_set_callback_receive_title( Instance, null );

            requestFileChooserCallback = null;
            awe_webview_set_callback_request_file_chooser( Instance, null );

            requestDownloadCallback = null;
            awe_webview_set_callback_request_download( Instance, null );

            requestMoveCallback = null;
            awe_webview_set_callback_request_move( Instance, null );

            updateIMECallback = null;
            awe_webview_set_callback_update_ime( Instance, null );

            webviewCrashedCallback = null;
            awe_webview_set_callback_web_view_crashed( Instance, null );

            selectionHelper.Dispose();
            selectionHelper = null;

            this.JSCallbackCalled -= handleJSCallback;

            if ( jsObjectCallbackMap != null )
            {
                jsObjectCallbackMap.Clear();
                jsObjectCallbackMap = null;
            }
        }
コード例 #4
0
ファイル: WebView.cs プロジェクト: Oceanswave/AwesomiumSharp
        internal WebView(IntPtr webview)
        {
            this.instance = webview;

            beginNavigationCallback = internalBeginNavigationCallback;
            awe_webview_set_callback_begin_navigation(webview, beginNavigationCallback);

            beginLoadingCallback = internalBeginLoadingCallback;
            awe_webview_set_callback_begin_loading(webview, beginLoadingCallback);

            finishLoadingCallback = internalFinishLoadingCallback;
            awe_webview_set_callback_finish_loading(webview, finishLoadingCallback);

            jsCallback = internalJsCallback;
            awe_webview_set_callback_js_callback(webview, jsCallback);

            receiveTitleCallback = internalReceiveTitleCallback;
            awe_webview_set_callback_receive_title(webview, receiveTitleCallback);

            changeTooltipCallback = internalChangeTooltipCallback;
            awe_webview_set_callback_change_tooltip(webview, changeTooltipCallback);

            changeCursorCallback = internalChangeCursorCallback;
            awe_webview_set_callback_change_cursor(webview, changeCursorCallback);

            changeKeyboardFocusCallback = internalChangeKeyboardFocusCallback;
            awe_webview_set_callback_change_keyboard_focus(webview, changeKeyboardFocusCallback);

            changeTargetURLCallback = internalChangeTargetURLCallback;
            awe_webview_set_callback_change_target_url(webview, changeTargetURLCallback);

            openExternalLinkCallback = internalOpenExternalLinkCallback;
            awe_webview_set_callback_open_external_link(webview, openExternalLinkCallback);

            requestDownloadCallback = internalRequestDownloadCallback;
            awe_webview_set_callback_request_download(webview, requestDownloadCallback);

            webviewCrashedCallback = internalWebviewCrashedCallback;
            awe_webview_set_callback_web_view_crashed(webview, webviewCrashedCallback);

            pluginCrashedCallback = internalPluginCrashedCallback;
            awe_webview_set_callback_plugin_crashed(webview, pluginCrashedCallback);

            requestMoveCallback = internalRequestMoveCallback;
            awe_webview_set_callback_request_move(webview, requestMoveCallback);

            getPageContentsCallback = internalGetPageContentsCallback;
            awe_webview_set_callback_get_page_contents(webview, getPageContentsCallback);

            domReadyCallback = internalDomReadyCallback;
            awe_webview_set_callback_dom_ready(webview, domReadyCallback);

            requestFileChooserCallback = internalRequestFileChooser;
            awe_webview_set_callback_request_file_chooser(webview, requestFileChooserCallback);

            getScrollDataCallback = internalGetScrollData;
            awe_webview_set_callback_get_scroll_data(webview, getScrollDataCallback);


            resourceRequestCallback = internalResourceRequestCallback;
            awe_webview_set_callback_resource_request(webview, resourceRequestCallback);

           // resourceResponseCallback = internalResourceResponseCallback;
           // awe_webview_set_callback_resource_response(webview, resourceResponseCallback);
        }