Dragorn421
1 year ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with
4 additions and
4 deletions
-
samples/XEmbedSample/Program.cs
-
src/Avalonia.X11/Dispatching/GLibDispatcherImpl.cs
-
src/Avalonia.X11/X11Platform.cs
|
|
|
@ -20,7 +20,7 @@ class Program |
|
|
|
.With(new X11PlatformOptions() |
|
|
|
{ |
|
|
|
UseGLibMainLoop = true, |
|
|
|
ExterinalGLibMainLoopExceptionLogger = e => Console.WriteLine(e.ToString()) |
|
|
|
ExternalGLibMainLoopExceptionLogger = e => Console.WriteLine(e.ToString()) |
|
|
|
}) |
|
|
|
.UseX11() |
|
|
|
.SetupWithoutStarting(); |
|
|
|
|
|
|
|
@ -237,7 +237,7 @@ internal class GlibDispatcherImpl : |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
var externalLogger = _platform.Options.ExterinalGLibMainLoopExceptionLogger; |
|
|
|
var externalLogger = _platform.Options.ExternalGLibMainLoopExceptionLogger; |
|
|
|
if (externalLogger != null) |
|
|
|
externalLogger.Invoke(e); |
|
|
|
else |
|
|
|
|
|
|
|
@ -384,8 +384,8 @@ namespace Avalonia |
|
|
|
/// will likely brick GLib machinery since it's not aware of managed Exceptions
|
|
|
|
/// This property allows to inspect such exceptions before they will be ignored
|
|
|
|
/// </summary>
|
|
|
|
public Action<Exception>? ExterinalGLibMainLoopExceptionLogger { get; set; } |
|
|
|
|
|
|
|
public Action<Exception>? ExternalGLibMainLoopExceptionLogger { get; set; } |
|
|
|
|
|
|
|
public X11PlatformOptions() |
|
|
|
{ |
|
|
|
try |
|
|
|
|