Skip to content

Commit d626c07

Browse files
committed
Re-enable web-source icons in Stable and Preview builds (#19137)
Disables a controversial part of #19044. Refs #19075 (cherry picked from commit 7b84162) Service-Card-Id: PVTI_lADOAF3p4s4AmhmQzgcqq7E Service-Version: 1.22
1 parent da05714 commit d626c07

File tree

2 files changed

+19
-3
lines changed

2 files changed

+19
-3
lines changed

src/cascadia/TerminalSettingsModel/CascadiaSettings.cpp

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -483,9 +483,14 @@ static bool _validateSingleMediaResource(std::wstring_view resource)
483483
return false;
484484
}
485485

486-
const auto scheme{ resourceUri.SchemeName() };
487-
// Only file: URIs and ms-* URIs are permissible. http, https, ftp, gopher, etc. are not.
488-
return til::equals_insensitive_ascii(scheme, L"file") || til::starts_with_insensitive_ascii(scheme, L"ms-");
486+
if constexpr (Feature_DisableWebSourceIcons::IsEnabled())
487+
{
488+
const auto scheme{ resourceUri.SchemeName() };
489+
// Only file: URIs and ms-* URIs are permissible. http, https, ftp, gopher, etc. are not.
490+
return til::equals_insensitive_ascii(scheme, L"file") || til::starts_with_insensitive_ascii(scheme, L"ms-");
491+
}
492+
493+
return true;
489494
}
490495
catch (...)
491496
{

src/features.xml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,4 +186,15 @@
186186
<alwaysDisabledReleaseTokens/>
187187
</feature>
188188

189+
<feature>
190+
<name>Feature_DisableWebSourceIcons</name>
191+
<description>Disables icon paths that make web requests</description>
192+
<id>19075</id>
193+
<stage>AlwaysDisabled</stage>
194+
<alwaysEnabledBrandingTokens>
195+
<brandingToken>Dev</brandingToken>
196+
<brandingToken>Canary</brandingToken>
197+
</alwaysEnabledBrandingTokens>
198+
</feature>
199+
189200
</featureStaging>

0 commit comments

Comments
 (0)