DSF.Net/Controllers/Ratio/HoriRatioxaml.xaml.cs
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace DSF.Net.Controllers.Ratio
{
/// <summary>
/// HoriRatioxaml.xaml 的交互逻辑
/// </summary>
public partial class HoriRatioxaml : UserControl
{
public HoriRatioxaml()
{
InitializeComponent();
labelLeft.MouseLeftButtonDown += Touch;
labelRight.MouseLeftButtonDown += Touch;
DataContext = this;
}
public event EventHandler ValueChanged;
private void Touch(object sender, MouseButtonEventArgs e)
{
Value = sender.Equals(labelLeft) ? HoriRatioStatus.LeftSelected : HoriRatioStatus.RightSelected;
ValueChanged?.Invoke(this, null);
}
public string TextLeft
{
get { return (string)GetValue(TextLeftProperty); }
set { SetValue(TextLeftProperty, value); }
}
public string TextRight
{
get { return (string)GetValue(TextRightProperty); }
set { SetValue(TextRightProperty, value); }
}
public HoriRatioStatus Value
{
get { return (HoriRatioStatus)GetValue(ValueProperty); }
set { SetValue(ValueProperty, value); }
}
public static readonly DependencyProperty TextLeftProperty =
DependencyProperty.Register("TextLeft", typeof(string), typeof(HoriRatioxaml), new PropertyMetadata("FINISHED", (s, e) =>
后面还有 20 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。