From 69531abb9c1f332ce0542a707944af4b96383dc6 Mon Sep 17 00:00:00 2001 From: lytico Date: Tue, 20 Jul 2021 01:52:18 +0200 Subject: [PATCH] Samples.csproj: WebviewSection: check for WebKit.Global.IsSupported --- Source/Samples/Sections/Widgets/WebviewSection.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Source/Samples/Sections/Widgets/WebviewSection.cs b/Source/Samples/Sections/Widgets/WebviewSection.cs index 7e1ede642..f63239813 100644 --- a/Source/Samples/Sections/Widgets/WebviewSection.cs +++ b/Source/Samples/Sections/Widgets/WebviewSection.cs @@ -19,6 +19,11 @@ namespace Samples public WebviewSection() { + if (!WebKit.Global.IsSupported) { + AddItem(($"{nameof(WebKit.WebView)}",new Label($"{typeof(WebView).Namespace} is not suported on your OS"))); + return; + } + AddItem(ShowHtml()); AddItem(ShowUri());