mirror of
https://github.com/cefsharp/CefSharp.git
synced 2026-12-04 10:22:55 +00:00
e8cf336bf3
- Make Wpf/WinForms/OffScreen projects target AnyCPU Only the VC++ projects are platform specific now. - Remove BrowserSubProcess project reference Not needed as we now have a standalone exe - Add OffScreen example - Add WPF Example project - Fix some compile errors for main solution - Add BrowserSubProcess executable - JavascriptObjectRepository remove isAsync param Rather than throw exception remove the option - BrowserSubprocess Exclude the WCF specific code from the netCore project - Add some ifdef/ifndef to exclude the WCF specific implementation - Move WCF implementation into separate namespace
38 lines
1.5 KiB
C#
38 lines
1.5 KiB
C#
// Copyright © 2020 The CefSharp Authors. All rights reserved.
|
|
//
|
|
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
|
|
|
|
using System.Diagnostics;
|
|
using CefSharp.RenderProcess;
|
|
|
|
namespace CefSharp.BrowserSubprocess
|
|
{
|
|
/// <summary>
|
|
/// When implementing your own BrowserSubprocess
|
|
/// - For .Net Core use <see cref="BrowserSubprocessExecutable"/> (No WCF Support)
|
|
/// - Include an app.manifest with the dpi/compatability sections, this is required (this project contains the relevant).
|
|
/// - If you are targeting x86/Win32 then you should set /LargeAddressAware (https://docs.microsoft.com/en-us/cpp/build/reference/largeaddressaware?view=vs-2017)
|
|
/// </summary>
|
|
public class Program
|
|
{
|
|
public static int Main(string[] args)
|
|
{
|
|
Debug.WriteLine("BrowserSubprocess starting up with command line: " + string.Join("\n", args));
|
|
|
|
SubProcess.EnableHighDPISupport();
|
|
|
|
//Add your own custom implementation of IRenderProcessHandler here
|
|
IRenderProcessHandler handler = null;
|
|
|
|
//The BrowserSubprocessExecutable provides BrowserSubProcess functionality
|
|
//specific to CefSharp there is no WCF support used for the sync JSB feature.
|
|
var browserProcessExe = new BrowserSubprocessExecutable();
|
|
var result = browserProcessExe.Main(args, handler);
|
|
|
|
Debug.WriteLine("BrowserSubprocess shutting down.");
|
|
|
|
return result;
|
|
}
|
|
}
|
|
}
|