Skip to content

Commit a46fcd9

Browse files
SERVCUBEDgolf1052
authored andcommitted
Set the status bar background colour on mobile
Set to the splash screen background colour
1 parent 79052ae commit a46fcd9

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

Signal-Windows/App.xaml.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,14 @@ private async Task OnLaunchedOrActivated(IActivatedEventArgs e, bool launched =
112112
LaunchActivatedEventArgs args = e as LaunchActivatedEventArgs;
113113
if (args.PrelaunchActivated == false)
114114
{
115+
if (Windows.Foundation.Metadata.ApiInformation.IsTypePresent("Windows.UI.ViewManagement.StatusBar"))
116+
{
117+
var sb = Windows.UI.ViewManagement.StatusBar.GetForCurrentView();
118+
sb.BackgroundColor = Windows.UI.Color.FromArgb(1, 0x20, 0x90, 0xEA);
119+
sb.BackgroundOpacity = 1;
120+
sb.ForegroundColor = Windows.UI.Colors.White;
121+
}
122+
115123
if (rootFrame.Content == null)
116124
{
117125
// Wenn der Navigationsstapel nicht wiederhergestellt wird, zur ersten Seite navigieren

Signal-Windows/Signal-Windows.csproj

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,11 @@
347347
<Version>2.2.9</Version>
348348
</PackageReference>
349349
</ItemGroup>
350+
<ItemGroup>
351+
<SDKReference Include="WindowsMobile, Version=10.0.16299.0">
352+
<Name>Windows Mobile Extensions for the UWP</Name>
353+
</SDKReference>
354+
</ItemGroup>
350355
<PropertyGroup Condition=" '$(VisualStudioVersion)' == '' or '$(VisualStudioVersion)' &lt; '14.0' ">
351356
<VisualStudioVersion>14.0</VisualStudioVersion>
352357
</PropertyGroup>

0 commit comments

Comments
 (0)