Commit Graph

25 Commits

Author SHA1 Message Date
amaitland 36dc1b7ece Core - Add Cef.ApiHash
Issue #5066
2025-03-16 13:11:10 +10:00
amaitland 1f682fcc85 Core - Cef.ChromiumVersion change to using System.Version
- After upgrading to VS `17.12.1` the String::Format code wouldn't compile
 in .Net Core 3.1
2024-11-23 09:44:38 +10:00
amaitland 606d9df7be Core - Add Cef.GetErrorCode
- Get the error code for when Cef.Initialize fails

Resolves #4914
2024-10-05 13:36:30 +10:00
amaitland 19739abd9c Remove Alloy Bootstrap (M128)
- Remove ChromeRuntime option
- Remove Extension Handling and related methods (no longer supported)
- Remove PackLoadingDisabled (no longer supported)
- Remove PersistUserPreferences (always on)

Resolves #4795
2024-09-18 17:53:17 +10:00
Alex Maitland 57f8cd344f Core - Change Cef.IsInitialized from bool to bool? (#4869)
Resolves #4867
2024-08-14 17:19:34 +10:00
Alex Maitland 3ac6487fcc Core - Add Cef.IsWindows10OrGreater and Cef.AssertIsWindows10OrGreater 2024-04-25 17:46:13 +10:00
Alex Maitland 2a9b50640f Core - Change from cef type defs to C++11 defs
https://bitbucket.org/chromiumembedded/cef/commits/5042d7140822cd13b80990f61ce2d3865864a3d8
2023-07-16 09:31:55 +10:00
Alex Maitland f14ecb69b9 Core - Remove Cef.EnableHighDPISupport
Resolves #4417
2023-03-15 18:26:35 +10:00
Alex Maitland c11b92912a Core - Cef.Initialize exception wording improvements 2022-11-08 14:57:59 +10:00
Alex Maitland f8530064b1 Core - Add Cef.PostAction and Cef.PostDelayedAction 2022-06-22 10:52:17 +10:00
Alex Maitland 2cd1c9b5ae Core - Add Cef.WaitForBrowsersToClose(int) overload
- Allow for specifying the timeout in ms
- Update the tests to 5000ms timeout
2022-06-20 13:03:15 +10:00
Alex Maitland 0673239fb7 Core - Cef.WaitForBrowsersToClose increase Wait Timeout
- After upgrading to M102 shutdown appears to be taking longer, so we'll increase
  the Wait timeout from 500ms to 750ms to allow CEF a little more time to finish processing.
2022-05-31 15:58:53 +10:00
Alex Maitland 20f836e2f2 Core - Add space to Cef.Shutdown thread check
- Improve readability
2022-05-09 10:10:13 +10:00
Alex Maitland 0ac43cf69f Core - Remove Remaining Plugin APIs
- Remove plugin references
- Update xml doc comments
- Update ref assembly (netcore)
- Update examples

Issue #4045
2022-03-21 10:01:26 +10:00
Alex Maitland 0fc3ae2323 Core - Add CefSettingsBase.IsDisposed
- Dispose CefSettingsBase
- Take a copy of the CefSettings struct and free our pointer
2021-11-25 09:45:29 +10:00
Alex Maitland 9993aa78e0 OffScreen - Create Browser when Global CefRequestContext initialized.
- GlobalContextInitialized wraps a TaskCompletionSource which is resolved
  when the Global CefRequestContext has been created
- Reduce code duplication

If successful we can apply the same changes to WinForms/WPF though they're less likely to have
issues than the OffScreen implementation as the CreateBrowser doesn't happen until much later

Issue #3850 #3634
2021-10-26 14:31:10 +10:00
Alex Maitland c5ba1ce430 Core - Add Cef.ParseUrl
Uses GURL to parse the Url (Google's URL parsing library)
2021-09-16 10:05:34 +10:00
Alex Maitland d350cad52a Update to M93 (#3781)
* Upgrade to CEF 93.1.7+g9117d6a+chromium-93.0.4577.42 / Chromium 93.0.4577.42

- Core - Add basic ref counting implementation

IMPLEMENT_REFCOUNTING implementation uses atomic which
forces the VC++ compiler to compile as native which doesn't work for our managed ref classes.

    - Use InterlockedCompareExchange for custom ref count reads
    - Use InterlockedIncrement/InterlockedDecrement directly
    - There's no memory barrier for HasOneRef/HasAtLeastOneRef as the read of a LONG should happen in one operation
on 32/64 bit architectures (at least that's my understanding at this point in time).

    References:
    https://github.com/chromiumembedded/cef/blob/4472/include/base/internal/cef_atomicops_x86_msvc.h#L125
    https://github.com/chromiumembedded/cef/blob/4472/include/base/internal/cef_atomicops_arm64_msvc.h#L107
    https://github.com/chromiumembedded/cef/blob/4472/include/base/cef_atomic_ref_count.h#L114
    https://github.com/chromiumembedded/cef/blob/4472/include/cef_base.h#L91

-  Remove Microsoft.Net.Compilers package from projects
Now that we require a min of VS2019 to build there's no need for a custom compiler package
- Start removing VS2015/VC++2015 references
- Remove RegisterWidevineCdm
This is a breaking change. CEF will now automatically download the Widevine CDM component
Resolves #3767

- RequestContext.LoadExtension now uses managed to code spawn on CEF UI Thread
Avoid having to use cef_callback.h which was causing problems for x86 builds
2021-09-03 10:51:18 +10:00
Jozef Izso 5d14f7c159 Add property Cef.IsShutdown to allow checks for the shutdown state of Cef runtime (#3782) (#3783) 2021-08-31 07:15:55 +10:00
Alex Maitland a18637facd C++/CLI - Replace NULL with nullptr
Issue #3636
2021-07-31 15:52:56 +10:00
Alex Maitland 018aefcda0 Core - Throw exception if calling Cef.Initialize after calling Cef.Shutdown 2021-07-31 15:52:54 +10:00
Alex Maitland ac0ef70a67 Core - Update FileThreadTaskFactory thread
TID_FILE was removed in commit https://bitbucket.org/chromiumembedded/cef/commits/ff8f4a7217189645a98b8affc45641cafe232f73
Use TID_FILE_BACKGROUND
2021-06-18 15:29:38 +10:00
Alex Maitland b4e189bf4f Core - Add Cef.GetMinLogLevel()
Gets the current log level
2021-01-27 13:39:04 +10:00
Alex Maitland 02d045832b Core - CefSettings no longer implements IDisposable
**This is a breaking change**

- CefSharp.Core.CefSettingsBase is now disposed when calling Cef.Initialize
- CefSharpApp was refactored to no longer need a reference to CefSettingsBase so it can be disposed

Resolves #3220
2020-12-31 17:08:08 +10:00
Alex Maitland 8a367fbdc4 Refactor CefSharp.Core into CefSharp.Core.Runtime (#3311)
* Net Core - Rename CefSharp.Core.dll to CefSharp.Core.Runtime.dll

Partial rename, only Net Core, folder not renamed

* Net Core - Rename CefSharp.Core.RefAssembly to CefSharp.Core.netcore

Remove GenApi

* Core - Rename CefDragDataWrapper to DragData

Move into CefSharp.Core namespace

* WinForms/WPF/OffScreen - Migrate from GitLink command line to Nuget package

* Net Core - Refactor to have CefSharp.Core.dll contain only public Api

* Net Core - Remove CefSharp.Core.RefAssembly

* Net Core - Change CefSharp.Core.netcore output folder

* Net Core - Restructure nuget packages

* Net Core - Add Cefsharp.Core.Runtime.RefAssembly

* Net Core - Hide CLI/C++ classes from intellisense

Make sure users don't attempt to load them directly

* Rename CefSharp.Core to CefSharp.Core.Runtime

* Core - Restructure Net 4.5.2 packages to use CefSharp.Core.dll anycpu variant

Attempt to load CefSharp.Core.Runtime at runtime rather than having to use msbuild to copy the correct version

* Rename CefSharp.Core.netcore to CefSharp.Core

* WPF/WinForms/OffScreen - Change from x86/64 to AnyCPU

As they are all managed assemblies they can target AnyCPU.
Includes CefSharp.dll

* Convert RequestContextBuilder from C++ to C#

Now part of the CefSharp.Core PublicApi

* Update version number to 87.1.11

* Migrate more of the public Api to C#

* Net Core - Basic restructure complete

* Net Core - ModuleInitializer (Doesn't work yet)

* Remove direct references to BrowserSettings

* Net Core - ModuleInitializer load CefShar.Core.Runtime.dl

* Net Core - Load libcef.dll via CLR Module initializer

If no RID is specified then we can load libcef.dll using the module initializer

* Add version to CefSharp.Core

* Remove dependency on CefSharp.Core.Runtime
Rewrite common targets

* AnyCPU app.config transform

Improve AnyCPU support

* Improve Net Core 3 support
Only delete CefSharp.Core.Runtime.dll when AnyCPU

* Nuget - Add CefSharp.Core.Runtime reference when TargetFramework = NetCore

* Fix Typos

Based on #3306

* Net Core - Rename CefSharp.Core.Runtime RefAssembly source file

* Net Full - Generate CefSharp.Core.Runtime Ref Assembly

For now the powershell build script generates the .cs file based on a x86 release build.ps1
It's not possible to directly install GenApi as it requires a Sdk style project

* Net Core - Old packages copy files to required folders

* Test - Install newer .Net Compiler and set Lang Version to 7.3

* Net Core - Exclude Net 452 Runtime generated reference source

* Core - Add Refactoring TODO

* Ref Assembly - Generate source as part of build

- Move ref assembly source generate into GenerateRefAssemblySource.ps1
- Call before project build

Runs locally, see if Appveyor has a problem with the powershell script execution

* Core - Add more factory methods to create instances of managed wrappers

* Net Core - Make Initialzier properties internal

Not quite sure what the public API should look like as yet, so making internal for now.
2020-12-16 10:47:34 +10:00