From 1eeb7439d8274624f1fda9341859ef6ce6f305a4 Mon Sep 17 00:00:00 2001 From: Brice Friha <37577669+bricefriha@users.noreply.github.com> Date: Tue, 29 Oct 2024 11:21:08 +0000 Subject: [PATCH 1/2] MAUI - Add documentation for SetBeforeScreenshotCapture option --- .../attach-screenshots/dotnet.maui.mdx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx b/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx index d9e120946dcf4..35b2215469e5c 100644 --- a/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx +++ b/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx @@ -5,5 +5,15 @@ var builder = MauiApp.CreateBuilder() { options.Dsn = "___PUBLIC_DSN___"; options.AttachScreenshot = true; + + // Set a Before Screenshot capture callback to execute some code before the screenshot is taken + options.SetBeforeScreenshotCapture((@event, hint) => + { + // + // Your code here + + // Return true to capture or false to prevent the capture + return true; + }); }) ``` From 230c836207ce33fb450aeb90dc5dd0d2968f38c0 Mon Sep 17 00:00:00 2001 From: Brice Friha <37577669+bricefriha@users.noreply.github.com> Date: Tue, 29 Oct 2024 11:39:43 +0000 Subject: [PATCH 2/2] maui - screenshots | adding more details to `SetBeforeScreenshotCapture` --- .../enriching-events/attach-screenshots/dotnet.maui.mdx | 1 + 1 file changed, 1 insertion(+) diff --git a/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx b/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx index 35b2215469e5c..df397b70ec26b 100644 --- a/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx +++ b/platform-includes/enriching-events/attach-screenshots/dotnet.maui.mdx @@ -7,6 +7,7 @@ var builder = MauiApp.CreateBuilder() options.AttachScreenshot = true; // Set a Before Screenshot capture callback to execute some code before the screenshot is taken + // This option is optional. if not set, the screenshots will be captured and sent. options.SetBeforeScreenshotCapture((@event, hint) => { //