mirror of
https://github.com/knah/VRCMelonAssistant.git
synced 2024-05-14 01:12:19 +12:00
Changed Icon and added loading screen to mods page
This commit is contained in:
parent
1f643e2a88
commit
709889fc35
|
@ -453,6 +453,9 @@ namespace ModAssistant
|
|||
ChangeColor(icons, "InfoIconColor", "info_circleDrawingGroup");
|
||||
ChangeColor(icons, "OptionsIconColor", "cogDrawingGroup");
|
||||
ChangeColor(icons, "ModsIconColor", "microchipDrawingGroup");
|
||||
ChangeColor(icons, "LoadingIconColor", "loadingInnerDrawingGroup");
|
||||
ChangeColor(icons, "LoadingIconColor", "loadingMiddleDrawingGroup");
|
||||
ChangeColor(icons, "LoadingIconColor", "loadingOuterDrawingGroup");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
@ -120,6 +120,9 @@
|
|||
<sys:String x:Key="Options:CurrentThemeRemoved">Options:CurrentThemeRemoved</sys:String>
|
||||
<sys:String x:Key="Options:ThemeFolderNotFound">Options:ThemeFolderNotFound</sys:String>
|
||||
|
||||
<!-- Loading Page -->
|
||||
<sys:String x:Key="Loading:Loading">Loading:Loading</sys:String>
|
||||
|
||||
<!-- Invalid Page -->
|
||||
<sys:String x:Key="Invalid:Title">Invalid:Title</sys:String>
|
||||
<sys:String x:Key="Invalid:PageTitle">Invalid:PageTitle</sys:String>
|
||||
|
|
|
@ -160,6 +160,9 @@
|
|||
<sys:String x:Key="Options:CurrentThemeRemoved">Current theme has been removed, reverting to default...</sys:String>
|
||||
<sys:String x:Key="Options:ThemeFolderNotFound">Themes folder not found! Try exporting the template...</sys:String>
|
||||
|
||||
<!-- Loading Page -->
|
||||
<sys:String x:Key="Loading:Loading">Loading Mods</sys:String>
|
||||
|
||||
<!-- Invalid Page -->
|
||||
<sys:String x:Key="Invalid:Title">Invalid</sys:String>
|
||||
<sys:String x:Key="Invalid:PageTitle">Invalid Installation Detected</sys:String>
|
||||
|
|
|
@ -8,5 +8,39 @@
|
|||
d:DesignHeight="450" d:DesignWidth="800"
|
||||
Title="Loading">
|
||||
|
||||
<Grid />
|
||||
<Page.Resources>
|
||||
<local:DivideDoubleByTwoConverter x:Key="DivideDoubleByTwoConverter"/>
|
||||
<Style x:Key="Spin" TargetType="{x:Type Image}">
|
||||
<Setter Property="RenderTransform">
|
||||
<Setter.Value>
|
||||
<RotateTransform Angle="0"
|
||||
CenterX="{Binding Path=ActualWidth, Converter={StaticResource DivideDoubleByTwoConverter}, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Image}}"
|
||||
CenterY="{Binding Path=ActualHeight, Converter={StaticResource DivideDoubleByTwoConverter}, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Image}}" />
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsEnabled" Value="True">
|
||||
<Trigger.EnterActions>
|
||||
<BeginStoryboard>
|
||||
<Storyboard x:Name="RotateStarCompass">
|
||||
<DoubleAnimation AutoReverse="False" Duration="0:0:3" From="0" To="360" Storyboard.TargetProperty="RenderTransform.Angle" RepeatBehavior="Forever"/>
|
||||
</Storyboard>
|
||||
</BeginStoryboard>
|
||||
</Trigger.EnterActions>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</Page.Resources>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<Image Margin="10" Grid.Row="0" Stretch="Uniform" Source="{DynamicResource loadingInnerDrawingImage}" VerticalAlignment="Center" />
|
||||
<Image Margin="10" Grid.Row="0" Stretch="Uniform" Source="{DynamicResource loadingMiddleDrawingImage}" VerticalAlignment="Center" />
|
||||
<Image Margin="10" Grid.Row="0" Stretch="Uniform" Source="{DynamicResource loadingOuterDrawingImage}" Style="{StaticResource Spin}" VerticalAlignment="Center" />
|
||||
|
||||
<TextBlock Grid.Row="1" VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="45" Margin="10" Text="{DynamicResource Loading:Loading}" />
|
||||
</Grid>
|
||||
</Page>
|
||||
|
|
|
@ -1,11 +1,13 @@
|
|||
using System.Windows.Controls;
|
||||
using System;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Data;
|
||||
|
||||
namespace ModAssistant.Pages
|
||||
{
|
||||
/// <summary>
|
||||
/// Interaction logic for Loading.xaml
|
||||
/// </summary>
|
||||
public sealed partial class Loading : Page
|
||||
public partial class Loading : Page
|
||||
{
|
||||
public static Loading Instance = new Loading();
|
||||
|
||||
|
@ -14,4 +16,23 @@ namespace ModAssistant.Pages
|
|||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
|
||||
[ValueConversion(typeof(double), typeof(double))]
|
||||
public class DivideDoubleByTwoConverter : IValueConverter
|
||||
{
|
||||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
if (targetType != typeof(double))
|
||||
{
|
||||
throw new InvalidOperationException("The target must be a double");
|
||||
}
|
||||
double d = (double)value;
|
||||
return ((double)d) / 2;
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,4 +25,22 @@
|
|||
<GeometryDrawing Brush="{DynamicResource ModsIconColor}" Geometry="{StaticResource microchipGeometry}" />
|
||||
</DrawingGroup>
|
||||
<DrawingImage x:Key="microchipDrawingImage" Drawing="{StaticResource microchipDrawingGroup}" />
|
||||
|
||||
<Geometry x:Key="loadingInnerGeometry">F1 M4000,4000z M0,0z M1833.4,1475.6C1827.5,1490 1818.3,1503.3 1805.8,1514.3 1762.7,1551.9 1697.3,1547.4 1659.7,1504.3 1628.8,1468.8 1626.4,1418.3 1650.5,1380.6L1170.6,1131.3 1336.5,1597.2C1394,1576.7 1460.7,1591.9 1503.2,1640.7 1558.7,1704.4 1552.1,1801.1 1488.4,1856.6 1473.5,1869.6 1456.7,1879.1 1439.1,1885.3L1814.9,2940.7 2747.8,2941 2875.1,2016.8 1833.4,1475.6z</Geometry>
|
||||
<DrawingGroup x:Key="loadingInnerDrawingGroup" ClipGeometry="M0,0 V4000 H4000 V0 H0 Z">
|
||||
<GeometryDrawing Brush="{DynamicResource LoadingIconColor}" Geometry="{StaticResource loadingInnerGeometry}" />
|
||||
</DrawingGroup>
|
||||
<DrawingImage x:Key="loadingInnerDrawingImage" Drawing="{DynamicResource loadingInnerDrawingGroup}" />
|
||||
|
||||
<Geometry x:Key="loadingMiddleGeometry">F1 M4000,4000z M0,0z M3384.4,1915.4C3385.5,2231.2 3278.1,2552.4 3057.5,2818.2 2570.1,3405.4 1714.7,3499.3 1146.9,3028 579.1,2556.7 514.1,1698.6 1001.5,1111.5 1222.2,845.7 1518.2,681 1828.8,624 1491,666 1167.9,831.7 933.3,1114.2 444.1,1703.5 525.3,2577.8 1114.5,3067 1703.7,3556.2 2578.1,3475.1 3067.3,2885.8 3301.9,2603.2 3405.2,2255.1 3384.4,1915.4z</Geometry>
|
||||
<DrawingGroup x:Key="loadingMiddleDrawingGroup" ClipGeometry="M0,0 V4000 H4000 V0 H0 Z">
|
||||
<GeometryDrawing Brush="{DynamicResource LoadingIconColor}" Geometry="{StaticResource loadingMiddleGeometry}" />
|
||||
</DrawingGroup>
|
||||
<DrawingImage x:Key="loadingMiddleDrawingImage" Drawing="{DynamicResource loadingMiddleDrawingGroup}" />
|
||||
|
||||
<Geometry x:Key="loadingOuterGeometry">F1 M4000,4000z M0,0z M3710.9,2000L3870,1840.9 3667.5,1638.4C3501.6,870.1 2818.3,294.3 2000.3,294.3 1182.4,294.3 499.1,870 333.2,1638.2L333,1637.9 130,1840.9 289.1,2000 130,2159.1 333,2362.1 333.2,2361.8C499.2,3130 1182.5,3705.6 2000.3,3705.6 2818.3,3705.6 3501.6,3129.8 3667.5,2361.5L3870,2159 3710.9,2000z M2000.3,3489.8C1177.5,3489.8 510.5,2822.8 510.5,2000 510.5,1177.2 1177.5,510.2 2000.3,510.2 2823.1,510.2 3490.1,1177.2 3490.1,2000 3490.1,2822.8 2823.1,3489.8 2000.3,3489.8z</Geometry>
|
||||
<DrawingGroup x:Key="loadingOuterDrawingGroup" ClipGeometry="M0,0 V4000 H4000 V0 H0 Z">
|
||||
<GeometryDrawing Brush="{DynamicResource LoadingIconColor}" Geometry="{StaticResource loadingOuterGeometry}" />
|
||||
</DrawingGroup>
|
||||
<DrawingImage x:Key="loadingOuterDrawingImage" Drawing="{DynamicResource loadingOuterDrawingGroup}" />
|
||||
</ResourceDictionary>
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 132 KiB After Width: | Height: | Size: 121 KiB |
|
@ -85,6 +85,7 @@
|
|||
<SolidColorBrush x:Key="ModsIconColor" Color="{DynamicResource ResourceKey=StandardIcon}" />
|
||||
<SolidColorBrush x:Key="AboutIconColor" Color="{DynamicResource ResourceKey=StandardIcon}" />
|
||||
<SolidColorBrush x:Key="OptionsIconColor" Color="{DynamicResource ResourceKey=StandardIcon}" />
|
||||
<SolidColorBrush x:Key="LoadingIconColor" Color="{DynamicResource ResourceKey=StandardContent}" />
|
||||
|
||||
<!--Background and Side image settings.-->
|
||||
<!-- Fill, None, Uniform, UniformToFill -->
|
||||
|
|
|
@ -73,6 +73,7 @@
|
|||
<SolidColorBrush x:Key="ModsIconColor" Color="White"/>
|
||||
<SolidColorBrush x:Key="AboutIconColor" Color="White"/>
|
||||
<SolidColorBrush x:Key="OptionsIconColor" Color="White"/>
|
||||
<SolidColorBrush x:Key="LoadingIconColor" Color="#101010" />
|
||||
|
||||
<!-- Background and Side image settings. -->
|
||||
<!-- Fill, None, Uniform, UniformToFill -->
|
||||
|
|
|
@ -84,6 +84,7 @@
|
|||
<SolidColorBrush x:Key="ModsIconColor" Color="#833BCE" />
|
||||
<SolidColorBrush x:Key="AboutIconColor" Color="#FF0000" />
|
||||
<SolidColorBrush x:Key="OptionsIconColor" Color="#4E3BCE" />
|
||||
<SolidColorBrush x:Key="LoadingIconColor" Color="#101010" />
|
||||
|
||||
<!-- Background and Side image settings. -->
|
||||
<!-- Fill, None, Uniform, UniformToFill -->
|
||||
|
|
|
@ -104,6 +104,8 @@
|
|||
<SolidColorBrush x:Key="AboutIconColor" Color="{DynamicResource ResourceKey=StandardIcon}"/>
|
||||
<!-- Options Default: #4E3BCE -->
|
||||
<SolidColorBrush x:Key="OptionsIconColor" Color="{DynamicResource ResourceKey=StandardIcon}"/>
|
||||
<!-- Loading Icon Default: #6D3B8B -->
|
||||
<SolidColorBrush x:Key="LoadingIconColor" Color="{DynamicResource ResourceKey=StandardContent}" />
|
||||
|
||||
<!-- Background and Side image settings. -->
|
||||
<!-- Fill, None, Uniform, UniformToFill -->
|
||||
|
|
Loading…
Reference in a new issue