Dark theme, navigation
This commit is contained in:
@@ -37,17 +37,17 @@
|
||||
<TextBlock TextWrapping="WrapWholeWords" Visibility="Collapsed" Text="Special thanks to contributors for motivating me, testers and translators for making this app better everyday and you for using this app;)" Margin="0,0,0,10"/>
|
||||
|
||||
<TextBlock Text="Contacts" FontSize="22" FontWeight="SemiBold"/>
|
||||
<TextBlock>Twitter: <Hyperlink NavigateUri="https://twitter.com/XFox_Mike" Foreground="Red">@XFox_Mike</Hyperlink></TextBlock>
|
||||
<TextBlock>Vkontakte: <Hyperlink NavigateUri="https://vk.com/XFox.Mike" Foreground="Red">@XFox.Mike</Hyperlink></TextBlock>
|
||||
<TextBlock>YouTube: <Hyperlink NavigateUri="https://youtube.com/c/FoxGameStudioChannel" Foreground="Red">@FoxGameStudioChannel</Hyperlink></TextBlock>
|
||||
<TextBlock>E-mail: <Hyperlink NavigateUri="mailto:michael.xfox@outlook.com" Foreground="Red">michael.xfox@outlook.com</Hyperlink></TextBlock>
|
||||
<TextBlock Margin="0,0,0,10">My blog (Russian language only): <Hyperlink NavigateUri="https://michael-xfox.com" Foreground="Red">https://michael-xfox.com</Hyperlink></TextBlock>
|
||||
<TextBlock>Twitter: <Hyperlink NavigateUri="https://twitter.com/XFox_Mike">@XFox_Mike</Hyperlink></TextBlock>
|
||||
<TextBlock>Vkontakte: <Hyperlink NavigateUri="https://vk.com/XFox.Mike">@XFox.Mike</Hyperlink></TextBlock>
|
||||
<TextBlock>YouTube: <Hyperlink NavigateUri="https://youtube.com/c/FoxGameStudioChannel">@FoxGameStudioChannel</Hyperlink></TextBlock>
|
||||
<TextBlock>E-mail: <Hyperlink NavigateUri="mailto:michael.xfox@outlook.com">michael.xfox@outlook.com</Hyperlink></TextBlock>
|
||||
<TextBlock Margin="0,0,0,10">My blog (Russian language only): <Hyperlink NavigateUri="https://michael-xfox.com">https://michael-xfox.com</Hyperlink></TextBlock>
|
||||
|
||||
<TextBlock Text="Legal stuff" FontSize="22" FontWeight="SemiBold"/>
|
||||
<HyperlinkButton Foreground="Red" Content="Our Privacy Policy" NavigateUri="https://michael-xfox.com/foxtubepp.txt" Padding="0,5,0,0"/>
|
||||
<HyperlinkButton Foreground="Red" Content="YouTube Privacy Policy" NavigateUri="https://youtube.com/t/privacy" Padding="0"/>
|
||||
<HyperlinkButton Foreground="Red" Content="YouTube Terms of use" NavigateUri="https://youtube.com/t/terms" Padding="0"/>
|
||||
<HyperlinkButton Foreground="Red" Content="YouTube Community Guidelines" NavigateUri="https://youtube.com/t/community_guidelines" Padding="0,0,0,10"/>
|
||||
<HyperlinkButton Content="Our Privacy Policy" NavigateUri="https://michael-xfox.com/foxtubepp.txt" Padding="0,5,0,0"/>
|
||||
<HyperlinkButton Content="YouTube Privacy Policy" NavigateUri="https://youtube.com/t/privacy" Padding="0"/>
|
||||
<HyperlinkButton Content="YouTube Terms of use" NavigateUri="https://youtube.com/t/terms" Padding="0"/>
|
||||
<HyperlinkButton Content="YouTube Community Guidelines" NavigateUri="https://youtube.com/t/community_guidelines" Padding="0,0,0,10"/>
|
||||
<TextBlock Text="© 2018 Michael Gordeev"/>
|
||||
<TextBlock Text="© 2018 YouTube, LLC"/>
|
||||
</StackPanel>
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Button Content="Submit feedback" Name="submit" Margin="0,10,10,10" Click="submit_Click" Background="Red" Foreground="White"/>
|
||||
<Button Content="Submit feedback" Name="submit" Margin="0,10,10,10" Click="submit_Click" Background="{ThemeResource SystemControlForegroundAccentBrush}" Foreground="White"/>
|
||||
<ProgressRing VerticalAlignment="Center" Name="ring" Foreground="Red"/>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
|
||||
@@ -39,5 +39,11 @@
|
||||
|
||||
<TextBlock Text="Notifications" FontSize="22"/>
|
||||
<ToggleSwitch Name="newVideo" OnContent="Notify when someone of your subscriptions uploaded new video" OffContent="Notify when someone of your subscriptions uploaded new video" Toggled="notification_IsEnabledChanged"/>
|
||||
|
||||
<TextBlock Text="Color mode" FontSize="22"/>
|
||||
<RadioButton Content="Light" Name="light" GroupName="color" Checked="RadioButton_Checked"/>
|
||||
<RadioButton Content="Dark" Name="dark" GroupName="color" Checked="RadioButton_Checked"/>
|
||||
<RadioButton Content="Windows default" Name="system" GroupName="color" Checked="RadioButton_Checked"/>
|
||||
<HyperlinkButton Content="Windows color settings" NavigateUri="ms-settings:colors"/>
|
||||
</StackPanel>
|
||||
</Page>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
@@ -39,6 +40,19 @@ namespace FoxTube.Pages.SettingsPages
|
||||
|
||||
safeSearch.SelectedIndex = (int)settings.Values["safeSearch"];
|
||||
|
||||
switch((int)settings.Values["themeMode"])
|
||||
{
|
||||
case 0:
|
||||
light.IsChecked = true;
|
||||
break;
|
||||
case 1:
|
||||
dark.IsChecked = true;
|
||||
break;
|
||||
case 2:
|
||||
system.IsChecked = true;
|
||||
break;
|
||||
}
|
||||
|
||||
foreach (CultureInfo culture in CultureInfo.GetCultures(CultureTypes.AllCultures))
|
||||
{
|
||||
region.Items.Add(culture.DisplayName);
|
||||
@@ -63,14 +77,9 @@ namespace FoxTube.Pages.SettingsPages
|
||||
|
||||
private void notification_IsEnabledChanged(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if ((bool)settings.Values["newVideoNotification"] != newVideo.IsOn)
|
||||
settings.Values["newVideoNotification"] = newVideo.IsOn;
|
||||
|
||||
if ((bool)settings.Values["moblieWarning"] != mobileWarning.IsOn)
|
||||
settings.Values["moblieWarning"] = mobileWarning.IsOn;
|
||||
|
||||
if ((bool)settings.Values["videoAutoplay"] != autoplay.IsOn)
|
||||
settings.Values["videoAutoplay"] = autoplay.IsOn;
|
||||
settings.Values["newVideoNotification"] = newVideo.IsOn;
|
||||
settings.Values["moblieWarning"] = mobileWarning.IsOn;
|
||||
settings.Values["videoAutoplay"] = autoplay.IsOn;
|
||||
}
|
||||
|
||||
private void region_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||
@@ -82,5 +91,24 @@ namespace FoxTube.Pages.SettingsPages
|
||||
{
|
||||
settings.Values["safeSearch"] = safeSearch.SelectedIndex;
|
||||
}
|
||||
|
||||
private void RadioButton_Checked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (sender == light)
|
||||
{
|
||||
settings.Values["themeMode"] = 0;
|
||||
Application.Current.RequestedTheme = ApplicationTheme.Light;
|
||||
}
|
||||
if (sender == dark)
|
||||
{
|
||||
settings.Values["themeMode"] = 1;
|
||||
Application.Current.RequestedTheme = ApplicationTheme.Dark;
|
||||
}
|
||||
if (sender == system)
|
||||
{
|
||||
settings.Values["themeMode"] = 2;
|
||||
Application.Current.RequestedTheme = ApplicationTheme.;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
<ColumnDefinition Width="0"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<ScrollViewer>
|
||||
<StackPanel VerticalAlignment="Stretch" Background="#FFF2F2F2">
|
||||
<StackPanel VerticalAlignment="Stretch">
|
||||
<ComboBox Header="Filter" Margin="10" HorizontalAlignment="Stretch" SelectedIndex="0" Name="filter" SelectionChanged="filter_SelectionChanged">
|
||||
<ComboBoxItem Content="All"/>
|
||||
<ComboBoxItem Content="Messages"/>
|
||||
|
||||
Reference in New Issue
Block a user