|
1234567891011121314151617181920212223242526272829303132333435363738394041 |
- using BPA.Helper;
- using System.Windows;
- using System.Windows.Controls;
-
- namespace BPASmartClient.Academy.View
- {
- /// <summary>
- /// RecipeSettingsView.xaml 的交互逻辑
- /// </summary>
- public partial class RecipeSettingsView : UserControl
- {
- public RecipeSettingsView()
- {
- InitializeComponent();
- this.Unloaded += RecipeSettingsView_Unloaded;
- }
-
- private void RecipeSettingsView_Unloaded(object sender, RoutedEventArgs e)
- {
- Json<LocalRecipe>.Save();
- }
-
- //public static void SetAlignment()
- //{
- // //获取系统是以Left-handed(true)还是Right-handed(false)
- // var ifLeft = SystemParameters.MenuDropAlignment;
-
- // if (ifLeft)
- // {
- // Console.WriteLine($"系统为左撇子,转换为右撇子。");
-
- // // change to false
- // var t = typeof(SystemParameters);
- // var field = t.GetField("_menuDropAlignment", BindingFlags.NonPublic | BindingFlags.Static);
- // field.SetValue(null, false);
-
- // ifLeft = SystemParameters.MenuDropAlignment;
- // }
- //}
- }
- }
|