mirror of
https://github.com/knah/VRCMelonAssistant.git
synced 2024-10-01 09:36:35 +13:00
38 lines
1 KiB
C#
38 lines
1 KiB
C#
using System;
|
|
using System.Windows.Controls;
|
|
using System.Windows.Data;
|
|
|
|
namespace ModAssistant.Pages
|
|
{
|
|
/// <summary>
|
|
/// Interaction logic for Loading.xaml
|
|
/// </summary>
|
|
public partial class Loading : Page
|
|
{
|
|
public static Loading Instance = new Loading();
|
|
|
|
public Loading()
|
|
{
|
|
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();
|
|
}
|
|
}
|
|
}
|