internal RenderProcessHandler(RenderProcess remoteProcess)
        {
            this.remoteProcess = remoteProcess;

            this.OnContextCreated += RenderProcessHandler_OnContextCreated;
            this.OnBrowserCreated += RenderProcessHandler_OnBrowserCreated;
        }
Beispiel #2
0
 internal static int RenderProcessMain()
 {
     try {
         var rp = new RenderProcess();
         HtmlUILauncher.RaiseRemoteProcessCreated(rp.processHandler);
         return rp.RemoteMain();
     } catch(CfxRemotingException) {
         return -1;
     }
 }
Beispiel #3
0
 internal static int RenderProcessMain()
 {
     try {
         var rp = new RenderProcess();
         HtmlUILauncher.RaiseRemoteProcessCreated(rp.processHandler);
         return(rp.RemoteMain());
     } catch (CfxRemotingException) {
         return(-1);
     }
 }
Beispiel #4
0
 public void SetRemoteBrowser(CfrBrowser remoteBrowser, RenderProcess remoteProcess)
 {
     this.remoteBrowser = remoteBrowser;
     this.remoteProcess = remoteProcess;
     remoteProcess.OnExit += new Action<RenderProcess>(remoteProcess_OnExit);
     var h = RemoteBrowserCreated;
     if (h != null)
     {
         var e = new RemoteBrowserCreatedEventArgs(remoteBrowser);
         if (RemoteCallbacksWillInvoke && InvokeRequired)
         {
             RenderThreadInvoke(() => { h(this, e); });
         }
         else
         {
             h(this, e);
         }
     }
 }
Beispiel #5
0
 void remoteProcess_OnExit(RenderProcess process)
 {
     if (process == this.remoteProcess)
     {
         this.remoteBrowser = null;
         this.remoteProcess = null;
     }
 }