Skip to content

Commit

Permalink
Drop statuse bar customization codes
Browse files Browse the repository at this point in the history
  • Loading branch information
ProJend committed Aug 26, 2021
1 parent 6230b1a commit 5bbb4ca
Show file tree
Hide file tree
Showing 12 changed files with 234 additions and 291 deletions.
5 changes: 5 additions & 0 deletions TrueLove.Lib/Models/UI/LocalSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ public static bool isBottomBarHidden
get => (bool)localSettings.Values["isBottomBarHidden"];
set => localSettings.Values["isBottomBarHidden"] = value;
}
public static bool isMidnightTheme
{
get => (bool)localSettings.Values["isMidnightTheme"];
set => localSettings.Values["isMidnightTheme"] = value;
}

public static ApplicationDataContainer localSettings = ApplicationData.Current.LocalSettings;
}
Expand Down
14 changes: 10 additions & 4 deletions TrueLove.UWP/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
using Windows.ApplicationModel.Activation;
using Windows.ApplicationModel.Core;
using Windows.UI;
using Windows.UI.Core;
using Windows.UI.ViewManagement;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
Expand Down Expand Up @@ -74,10 +75,10 @@ protected override void OnLaunched(LaunchActivatedEventArgs e)
a = null;
}

if (Generic.DeviceFamilyMatch(DeviceFamilyType.Mobile))
HideStatusBar();
else
if (Generic.DeviceFamilyMatch(DeviceFamilyType.Desktop))
HideTitleBar();
//else
// HideStatusBar();
}
}

Expand Down Expand Up @@ -148,7 +149,12 @@ private void HideStatusBar()
{
var applicationView = ApplicationView.GetForCurrentView();
applicationView.SetDesiredBoundsMode(ApplicationViewBoundsMode.UseCoreWindow);
applicationView.VisibleBoundsChanged += MainPage.Current.VisibleBounds_Changed;
var s = StatusBar.GetForCurrentView();

applicationView.VisibleBoundsChanged += (e,o) =>
{

};
}
}
}
2 changes: 1 addition & 1 deletion TrueLove.UWP/Package.appxmanifest
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Package xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10" xmlns:mp="http://schemas.microsoft.com/appx/2014/phone/manifest" xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10" IgnorableNamespaces="uap mp">
<Identity Name="Tim" Publisher="CN=Admin" Version="0.2.38.0" />
<Identity Name="Tim" Publisher="CN=Admin" Version="0.3.0.0" />
<mp:PhoneIdentity PhoneProductId="cf0148d5-01bb-4b60-b53b-da3346bf8e5e" PhonePublisherId="00000000-0000-0000-0000-000000000000" />
<Properties>
<DisplayName>True Love - Tim Bergling Foundtion</DisplayName>
Expand Down
4 changes: 2 additions & 2 deletions TrueLove.UWP/Template/Button.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -326,8 +326,8 @@
<Style x:Name="BasicGhostBotton" TargetType="Button" x:Key="GhostBotton">
<Style.Setters>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Width" Value="42"/>
<Setter Property="Height" Value="42"/>
<Setter Property="Width" Value="40"/>
<Setter Property="Height" Value="40"/>
</Style.Setters>
</Style>
</ResourceDictionary>
34 changes: 5 additions & 29 deletions TrueLove.UWP/Template/Colors.xaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:muxm="using:Microsoft.UI.Xaml.Media"
xmlns:date="using:TrueLove.Lib.Models.UI">
xmlns:muxm="using:Microsoft.UI.Xaml.Media">
<ResourceDictionary.ThemeDictionaries>
<ResourceDictionary x:Key="Dark">
<Color x:Key="PageBackgroundColor">Black</Color>
Expand All @@ -15,23 +14,11 @@
<Color x:Key="SystemAccentColorDark2">#18797B</Color>
<Color x:Key="SystemAccentColorDark3">#136263</Color>

<muxm:RevealBackgroundBrush x:Key="AccentRevealBackgroundBrush"
FallbackColor="{ThemeResource SystemAccentColor}"
TargetTheme="Dark"
Color="{ThemeResource SystemAccentColor}"/>
<muxm:RevealBackgroundBrush x:Key="DarkAccentRevealBackgroundBrush"
FallbackColor="{ThemeResource SystemAccentColorDark2}"
TargetTheme="Dark"
Color="{ThemeResource SystemAccentColorDark2}"/>
<muxm:RevealBackgroundBrush x:Key="LightAccentRevealBackgroundBrush"
FallbackColor="{ThemeResource SystemAccentColorLight3}"
TargetTheme="Dark"
Color="{ThemeResource SystemAccentColorLight3}"/>
<muxm:AcrylicBrush x:Key="NavigationViewDefaultPaneBackground"
BackgroundSource="Backdrop"
TintColor="Black"
TintOpacity=".5"
FallbackColor="Black"/>
FallbackColor="#FF1F1F1F"/>
<muxm:AcrylicBrush x:Key="NavigationViewTopPaneBackground"
BackgroundSource="Backdrop"
TintColor="#00000001"
Expand All @@ -44,20 +31,9 @@
</ResourceDictionary>
<ResourceDictionary x:Key="HighContrast">
<Color x:Key="SystemAccentColor">#1AEBFF</Color>
<muxm:AcrylicBrush x:Key="NavigationViewDefaultPaneBackground"
BackgroundSource="Backdrop"
TintColor="#00000001"
TintOpacity=".5"
FallbackColor="Black"/>
<muxm:AcrylicBrush x:Key="NavigationViewTopPaneBackground"
BackgroundSource="Backdrop"
TintColor="#00000001"
TintOpacity=".6"
FallbackColor="Black"/>
<muxm:AcrylicBrush x:Key="NavigationViewExpandedPaneBackground"
BackgroundSource="HostBackdrop"
TintColor="Black"
TintOpacity=".5"/>
<SolidColorBrush Color="Black" x:Key="NavigationViewDefaultPaneBackground"/>
<SolidColorBrush Color="Black" x:Key="NavigationViewTopPaneBackground"/>
<SolidColorBrush Color="Black" x:Key="NavigationViewExpandedPaneBackground"/>
</ResourceDictionary>
</ResourceDictionary.ThemeDictionaries>
</ResourceDictionary>
4 changes: 0 additions & 4 deletions TrueLove.UWP/Template/Navigation.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:NotOver15063="http://schemas.microsoft.com/winfx/2006/xaml/presentation?IsApiContractNotPresent(Windows.Foundation.UniversalApiContract, 5)"
xmlns:Over15063="http://schemas.microsoft.com/winfx/2006/xaml/presentation?IsApiContractPresent(Windows.Foundation.UniversalApiContract, 5)"
xmlns:Over17763="http://schemas.microsoft.com/winfx/2006/xaml/presentation?IsApiContractPresent(Windows.Foundation.UniversalApiContract, 7)"
xmlns:muxc="using:Microsoft.UI.Xaml.Controls">
Expand Down Expand Up @@ -86,9 +85,6 @@
<VisualState.Setters>
<Setter Target="HeaderContent.Visibility" Value="Visible"/>
<Setter Target="HeaderContent.Margin" Value="14 6 0 0"/>
<NotOver15063:Setter Target="HeaderContent.Margin" Value="14 29 0 0"/>
<NotOver15063:Setter Target="Bar.Height" Value="23"/>
<NotOver15063:Setter Target="ContentPaneTopPadding.Margin" Value="0 6 0 0"/>
</VisualState.Setters>
</VisualState>
</VisualStateGroup>
Expand Down
163 changes: 84 additions & 79 deletions TrueLove.UWP/Views/DeviceFamily-Mobile/HomePage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,97 +42,102 @@
</ItemsPanelTemplate>
</Page.Resources>

<FlipView SelectionChanged="FlipView_SelectionChanged" x:Name="flipview" Background="Transparent">
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<Grid>
<FlipView SelectionChanged="FlipView_SelectionChanged" x:Name="flipview"
Margin="0 1 0 1">
<FlipView.Background>
<ImageBrush ImageSource="/Assets/Background.jpg" Stretch="UniformToFill" AlignmentX="Left" AlignmentY="Bottom"/>
</FlipView.Background>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>

<StackPanel Name="FloatingLayout_a">
<TextBlock Text="the Avicii UWP" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center" Style="{StaticResource TitleTextBlockStyle}"/>
<TextBlock Text="TIM BERGLING" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource BodyTextBlockStyle}"/>
<TextBlock Text="FOUNDATION" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource BodyTextBlockStyle}"/>
<TextBlock Text="1989.09.08 - 2018.04.20" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource CaptionTextBlockStyle}"/>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<StackPanel Name="FloatingLayout_a">
<TextBlock Text="the Avicii UWP" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center" Style="{StaticResource TitleTextBlockStyle}"/>
<TextBlock Text="TIM BERGLING" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource BodyTextBlockStyle}"/>
<TextBlock Text="FOUNDATION" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource BodyTextBlockStyle}"/>
<TextBlock Text="1989.09.08 - 2018.04.20" HorizontalAlignment="Center" CharacterSpacing="350" Style="{StaticResource CaptionTextBlockStyle}"/>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>

<StackPanel Name="FloatingLayout_b">
<TextBlock Text="Avicii Memory boaid" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center" Style="{StaticResource TitleTextBlockStyle}"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBlock Text="COMMENTS" Style="{StaticResource BodyTextBlockStyle}" VerticalAlignment="Center" CharacterSpacing="350" Margin="40 0 0 2"/>
<Button Background="Transparent" Width="40" Height="40" Click="LinkingPage_Click"
<StackPanel Name="FloatingLayout_b">
<TextBlock Text="Avicii Memory boaid" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center" Style="{StaticResource TitleTextBlockStyle}"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBlock Text="COMMENTS" Style="{StaticResource BodyTextBlockStyle}" VerticalAlignment="Center" CharacterSpacing="350" Margin="40 0 0 2"/>
<Button Style="{StaticResource GhostBotton}" Click="LinkingPage_Click"
Tag="linkingCommentsPage" Over17763:CornerRadius="20">
<FontIcon Foreground="{ThemeResource SystemAccentColor}" FontFamily="Segoe MDL2 Assets" Glyph="&#xE761;"/>
</Button>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBlock Text="IMAGES" Style="{StaticResource BodyTextBlockStyle}" CharacterSpacing="350"
<FontIcon Foreground="{ThemeResource SystemAccentColor}" FontFamily="Segoe MDL2 Assets" Glyph="&#xE761;"/>
</Button>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBlock Text="IMAGES" Style="{StaticResource BodyTextBlockStyle}" CharacterSpacing="350"
VerticalAlignment="Center" Margin="40 0 0 2"/>
<Button Background="Transparent" Width="40" Height="40" Click="LinkingPage_Click"
<Button Style="{StaticResource GhostBotton}" Click="LinkingPage_Click"
Tag="linkingImagesPage" Over17763:CornerRadius="20">
<FontIcon Foreground="{ThemeResource SystemAccentColor}" FontFamily="Segoe MDL2 Assets" Glyph="&#xE761;"/>
</Button>
</StackPanel>
<TextBlock Text="IN LOVING MEMORY" HorizontalAlignment="Center" CharacterSpacing="350"
<FontIcon Foreground="{ThemeResource SystemAccentColor}" FontFamily="Segoe MDL2 Assets" Glyph="&#xE761;"/>
</Button>
</StackPanel>
<TextBlock Text="IN LOVING MEMORY" HorizontalAlignment="Center" CharacterSpacing="350"
Style="{StaticResource CaptionTextBlockStyle}"/>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>

<StackPanel Name="FloatingLayout_c">
<TextBlock Text="◢◤" HorizontalAlignment="Center" FontSize="30"/>
<TextBlock Text="Remembering Tim Bergling" Style="{StaticResource TitleTextBlockStyle}" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center"/>
<TextBlock MaxWidth="350" Style="{ThemeResource CaptionTextBlockStyle}" TextAlignment="Center">
<StackPanel Name="FloatingLayout_c">
<TextBlock Text="◢◤" HorizontalAlignment="Center" FontSize="30"/>
<TextBlock Text="Remembering Tim Bergling" Style="{StaticResource TitleTextBlockStyle}" FontFamily="{StaticResource freeland}" HorizontalAlignment="Center"/>
<TextBlock MaxWidth="350" Style="{ThemeResource CaptionTextBlockStyle}" TextAlignment="Center">
<LineBreak/>
<Run>Tim created music that brought people together with timeless memories from all over the world.</Run><LineBreak/><LineBreak/>
<Run>We created this space so you could share your memories with all of us and let the world know what Avicii meant to you.</Run><LineBreak/><LineBreak/>
<Run>His music and your memories are forever.</Run>
</TextBlock>
</TextBlock>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<ProgressRing Name="LoadingImages" Foreground="White" IsActive="True" Width="50" Height="50" Margin="0 0 0 30"/>
<TextBlock Style="{ThemeResource TitleTextBlockStyle}" CharacterSpacing="350" HorizontalAlignment="Center" Margin="0 0 0 15" Text="INSTAGRAM"/>
<Viewbox>
<GridView x:Name="ImageGridView" ScrollViewer.HorizontalScrollMode="Disabled" ScrollViewer.VerticalScrollMode="Disabled" ItemContainerStyle="{StaticResource GridViewItemNoneStyle}">
<GridView.ItemTemplate>
<DataTemplate>
<Image Stretch="UniformToFill" Source="{Binding}"/>
</DataTemplate>
</GridView.ItemTemplate>
</GridView>
</Viewbox>
</StackPanel>
</Grid>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<ProgressRing Name="LoadingImages" Foreground="White" IsActive="True" Width="50" Height="50" Margin="0 0 0 30"/>
<TextBlock Style="{ThemeResource TitleTextBlockStyle}" CharacterSpacing="350" HorizontalAlignment="Center" Margin="0 0 0 15" Text="INSTAGRAM"/>
<Viewbox>
<GridView x:Name="ImageGridView" ScrollViewer.HorizontalScrollMode="Disabled" ScrollViewer.VerticalScrollMode="Disabled" ItemContainerStyle="{StaticResource GridViewItemNoneStyle}">
<GridView.ItemTemplate>
<DataTemplate>
<Image Stretch="UniformToFill" Source="{Binding}"/>
</DataTemplate>
</GridView.ItemTemplate>
</GridView>
</Viewbox>
</StackPanel>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid Background="Black">
<Image Source="/Assets/SplashScreen.png" Height="150" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Grid>
</FlipViewItem>

<FlipView.ItemsPanel>
<ItemsPanelTemplate>
<VirtualizingStackPanel AreScrollSnapPointsRegular="True" Orientation="Vertical"/>
</ItemsPanelTemplate>
</FlipView.ItemsPanel>
</FlipViewItem>
<FlipViewItem ManipulationMode="System,TranslateX" IsTabStop="False">
<Grid Background="Black">
<Image Source="/Assets/SplashScreen.png" Height="150" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Grid>
</FlipViewItem>

<FlipView.ItemsPanel>
<ItemsPanelTemplate>
<VirtualizingStackPanel AreScrollSnapPointsRegular="True" Orientation="Vertical"/>
</ItemsPanelTemplate>
</FlipView.ItemsPanel>
</FlipView>
<VisualStateManager.VisualStateGroups>
<VisualStateGroup>
<VisualState>
Expand Down Expand Up @@ -171,5 +176,5 @@
</VisualState>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
</FlipView>
</Grid>
</Page>
Loading

0 comments on commit 5bbb4ca

Please sign in to comment.