2024-05-01 18:23:32 +08:00
|
|
|
|
using Ink_Canvas.Helpers;
|
|
|
|
|
using Newtonsoft.Json;
|
|
|
|
|
using System;
|
|
|
|
|
using System.Reflection;
|
|
|
|
|
using System.Windows;
|
2024-05-12 14:23:50 +08:00
|
|
|
|
using System.Windows.Controls;
|
|
|
|
|
using System.Windows.Ink;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
using System.Windows.Media;
|
2024-05-13 01:54:04 +08:00
|
|
|
|
using System.Windows.Media.Imaging;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
using File = System.IO.File;
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
namespace Ink_Canvas {
|
|
|
|
|
public partial class MainWindow : Window {
|
|
|
|
|
private void LoadSettings(bool isStartup = false) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
AppVersionTextBlock.Text = Assembly.GetExecutingAssembly().GetName().Version.ToString();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
try {
|
|
|
|
|
if (File.Exists(App.RootPath + settingsFileName)) {
|
|
|
|
|
try {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
string text = File.ReadAllText(App.RootPath + settingsFileName);
|
|
|
|
|
Settings = JsonConvert.DeserializeObject<Settings>(text);
|
2024-06-04 21:21:08 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
catch { }
|
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
BtnResetToSuggestion_Click(null, null);
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
catch (Exception ex) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
LogHelper.WriteLogToFile(ex.ToString(), LogHelper.LogType.Error);
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Startup
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (isStartup) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
CursorIcon_Click(null, null);
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
try {
|
2024-06-04 21:21:08 +08:00
|
|
|
|
if (File.Exists(Environment.GetFolderPath(Environment.SpecialFolder.Startup) +
|
2024-06-10 18:05:32 +08:00
|
|
|
|
"\\Ink Canvas Annotation.lnk")) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchRunAtStartup.IsOn = true;
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
catch (Exception ex) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
LogHelper.WriteLogToFile(ex.ToString(), LogHelper.LogType.Error);
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Startup != null) {
|
|
|
|
|
if (isStartup) {
|
|
|
|
|
if (Settings.Automation.AutoDelSavedFiles) {
|
2024-06-04 21:21:08 +08:00
|
|
|
|
DelAutoSavedFiles.DeleteFilesOlder(Settings.Automation.AutoSavedStrokesLocation,
|
|
|
|
|
Settings.Automation.AutoDelSavedFilesDaysThreshold);
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Startup.IsFoldAtStartup) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
FoldFloatingBar_MouseUp(Fold_Icon, null);
|
|
|
|
|
}
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Startup.IsEnableNibMode) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchEnableNibMode.IsOn = true;
|
2024-06-06 20:09:23 +08:00
|
|
|
|
BoardToggleSwitchEnableNibMode.IsOn = true;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
BoundsWidth = Settings.Advanced.NibModeBoundsWidth;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchEnableNibMode.IsOn = false;
|
2024-06-06 20:09:23 +08:00
|
|
|
|
BoardToggleSwitchEnableNibMode.IsOn = false;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
BoundsWidth = Settings.Advanced.FingerModeBoundsWidth;
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Startup.IsAutoUpdate) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchIsAutoUpdate.IsOn = true;
|
|
|
|
|
AutoUpdate();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-12 14:23:50 +08:00
|
|
|
|
// ToggleSwitchIsAutoUpdateWithSilence.Visibility = Settings.Startup.IsAutoUpdate ? Visibility.Visible : Visibility.Collapsed;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Startup.IsAutoUpdateWithSilence) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchIsAutoUpdateWithSilence.IsOn = true;
|
|
|
|
|
}
|
|
|
|
|
|
2024-06-04 21:21:08 +08:00
|
|
|
|
AutoUpdateTimePeriodBlock.Visibility = Settings.Startup.IsAutoUpdateWithSilence
|
|
|
|
|
? Visibility.Visible
|
|
|
|
|
: Visibility.Collapsed;
|
|
|
|
|
|
|
|
|
|
AutoUpdateWithSilenceTimeComboBox.InitializeAutoUpdateWithSilenceTimeComboBoxOptions(
|
|
|
|
|
AutoUpdateWithSilenceStartTimeComboBox, AutoUpdateWithSilenceEndTimeComboBox);
|
2024-05-01 18:23:32 +08:00
|
|
|
|
AutoUpdateWithSilenceStartTimeComboBox.SelectedItem = Settings.Startup.AutoUpdateWithSilenceStartTime;
|
|
|
|
|
AutoUpdateWithSilenceEndTimeComboBox.SelectedItem = Settings.Startup.AutoUpdateWithSilenceEndTime;
|
|
|
|
|
|
|
|
|
|
ToggleSwitchFoldAtStartup.IsOn = Settings.Startup.IsFoldAtStartup;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Startup = new Startup();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Appearance
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Appearance != null) {
|
|
|
|
|
if (!Settings.Appearance.IsEnableDisPlayNibModeToggler) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
NibModeSimpleStackPanel.Visibility = Visibility.Collapsed;
|
|
|
|
|
BoardNibModeSimpleStackPanel.Visibility = Visibility.Collapsed;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
NibModeSimpleStackPanel.Visibility = Visibility.Visible;
|
|
|
|
|
BoardNibModeSimpleStackPanel.Visibility = Visibility.Visible;
|
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
|
2024-05-13 01:54:04 +08:00
|
|
|
|
//if (Settings.Appearance.IsColorfulViewboxFloatingBar) // 浮动工具栏背景色
|
|
|
|
|
//{
|
|
|
|
|
// LinearGradientBrush gradientBrush = new LinearGradientBrush();
|
|
|
|
|
// gradientBrush.StartPoint = new Point(0, 0);
|
|
|
|
|
// gradientBrush.EndPoint = new Point(1, 1);
|
|
|
|
|
// GradientStop blueStop = new GradientStop(Color.FromArgb(0x95, 0x80, 0xB0, 0xFF), 0);
|
|
|
|
|
// GradientStop greenStop = new GradientStop(Color.FromArgb(0x95, 0xC0, 0xFF, 0xC0), 1);
|
|
|
|
|
// gradientBrush.GradientStops.Add(blueStop);
|
|
|
|
|
// gradientBrush.GradientStops.Add(greenStop);
|
|
|
|
|
// EnableTwoFingerGestureBorder.Background = gradientBrush;
|
|
|
|
|
// BorderFloatingBarMainControls.Background = gradientBrush;
|
|
|
|
|
// BorderFloatingBarMoveControls.Background = gradientBrush;
|
|
|
|
|
// BorderFloatingBarExitPPTBtn.Background = gradientBrush;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-05-13 01:54:04 +08:00
|
|
|
|
// ToggleSwitchColorfulViewboxFloatingBar.IsOn = true;
|
|
|
|
|
//} else {
|
|
|
|
|
// EnableTwoFingerGestureBorder.Background = (Brush)FindResource("FloatBarBackground");
|
|
|
|
|
// BorderFloatingBarMainControls.Background = (Brush)FindResource("FloatBarBackground");
|
|
|
|
|
// BorderFloatingBarMoveControls.Background = (Brush)FindResource("FloatBarBackground");
|
|
|
|
|
// BorderFloatingBarExitPPTBtn.Background = (Brush)FindResource("FloatBarBackground");
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-05-13 01:54:04 +08:00
|
|
|
|
// ToggleSwitchColorfulViewboxFloatingBar.IsOn = false;
|
|
|
|
|
//}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
|
2024-05-13 01:54:04 +08:00
|
|
|
|
if (Settings.Appearance.ViewboxFloatingBarScaleTransformValue != 0) // 浮动工具栏 UI 缩放 85%
|
2024-05-01 18:23:32 +08:00
|
|
|
|
{
|
2024-05-13 01:54:04 +08:00
|
|
|
|
double val = Settings.Appearance.ViewboxFloatingBarScaleTransformValue;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
ViewboxFloatingBarScaleTransform.ScaleX =
|
|
|
|
|
(val > 0.5 && val < 1.25) ? val : val <= 0.5 ? 0.5 : val >= 1.25 ? 1.25 : 1;
|
|
|
|
|
ViewboxFloatingBarScaleTransform.ScaleY =
|
|
|
|
|
(val > 0.5 && val < 1.25) ? val : val <= 0.5 ? 0.5 : val >= 1.25 ? 1.25 : 1;
|
2024-05-13 01:54:04 +08:00
|
|
|
|
ViewboxFloatingBarScaleTransformValueSlider.Value = val;
|
|
|
|
|
}
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-05-13 01:54:04 +08:00
|
|
|
|
ComboBoxUnFoldBtnImg.SelectedIndex = Settings.Appearance.UnFoldButtonImageType;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
switch (Settings.Appearance.UnFoldButtonImageType) {
|
|
|
|
|
case 0:
|
|
|
|
|
RightUnFoldBtnImgChevron.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/new-icons/unfold-chevron.png"));
|
|
|
|
|
RightUnFoldBtnImgChevron.Width = 14;
|
|
|
|
|
RightUnFoldBtnImgChevron.Height = 14;
|
|
|
|
|
RightUnFoldBtnImgChevron.RenderTransform = new RotateTransform(180);
|
|
|
|
|
LeftUnFoldBtnImgChevron.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/new-icons/unfold-chevron.png"));
|
|
|
|
|
LeftUnFoldBtnImgChevron.Width = 14;
|
|
|
|
|
LeftUnFoldBtnImgChevron.Height = 14;
|
|
|
|
|
LeftUnFoldBtnImgChevron.RenderTransform = null;
|
|
|
|
|
break;
|
|
|
|
|
case 1:
|
|
|
|
|
RightUnFoldBtnImgChevron.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/new-icons/pen-white.png"));
|
|
|
|
|
RightUnFoldBtnImgChevron.Width = 18;
|
|
|
|
|
RightUnFoldBtnImgChevron.Height = 18;
|
|
|
|
|
RightUnFoldBtnImgChevron.RenderTransform = null;
|
|
|
|
|
LeftUnFoldBtnImgChevron.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/new-icons/pen-white.png"));
|
|
|
|
|
LeftUnFoldBtnImgChevron.Width = 18;
|
|
|
|
|
LeftUnFoldBtnImgChevron.Height = 18;
|
|
|
|
|
LeftUnFoldBtnImgChevron.RenderTransform = null;
|
|
|
|
|
break;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
2024-05-13 01:54:04 +08:00
|
|
|
|
|
2024-06-07 21:27:16 +08:00
|
|
|
|
ComboBoxChickenSoupSource.SelectedIndex = Settings.Appearance.ChickenSoupSource;
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableQuickPanel.IsOn = Settings.Appearance.IsShowQuickPanel;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-08 19:53:18 +08:00
|
|
|
|
ViewboxFloatingBar.Opacity = Settings.Appearance.ViewboxFloatingBarOpacityValue;
|
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
if (Settings.Appearance.EnableViewboxBlackBoardScaleTransform) // 画板 UI 缩放 80%
|
|
|
|
|
{
|
2024-06-09 15:14:58 +08:00
|
|
|
|
//ViewboxBlackboardLeftSideScaleTransform.ScaleX = 0.8;
|
|
|
|
|
//ViewboxBlackboardLeftSideScaleTransform.ScaleY = 0.8;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ViewboxBlackboardCenterSideScaleTransform.ScaleX = 0.8;
|
|
|
|
|
ViewboxBlackboardCenterSideScaleTransform.ScaleY = 0.8;
|
2024-06-09 15:14:58 +08:00
|
|
|
|
//ViewboxBlackboardRightSideScaleTransform.ScaleX = 0.8;
|
|
|
|
|
//ViewboxBlackboardRightSideScaleTransform.ScaleY = 0.8;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
|
|
|
|
ToggleSwitchEnableViewboxBlackBoardScaleTransform.IsOn = true;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-06-09 15:14:58 +08:00
|
|
|
|
//ViewboxBlackboardLeftSideScaleTransform.ScaleX = 1;
|
|
|
|
|
//ViewboxBlackboardLeftSideScaleTransform.ScaleY = 1;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ViewboxBlackboardCenterSideScaleTransform.ScaleX = 1;
|
|
|
|
|
ViewboxBlackboardCenterSideScaleTransform.ScaleY = 1;
|
2024-06-09 15:14:58 +08:00
|
|
|
|
//ViewboxBlackboardRightSideScaleTransform.ScaleX = 1;
|
|
|
|
|
//ViewboxBlackboardRightSideScaleTransform.ScaleY = 1;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
|
|
|
|
ToggleSwitchEnableViewboxBlackBoardScaleTransform.IsOn = false;
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Appearance.IsTransparentButtonBackground) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
BtnExit.Background = new SolidColorBrush(StringToColor("#7F909090"));
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
|
|
|
|
//Light
|
|
|
|
|
BtnExit.Background = BtnSwitchTheme.Content.ToString() == "深色"
|
|
|
|
|
? new SolidColorBrush(StringToColor("#FFCCCCCC"))
|
|
|
|
|
:
|
2024-05-01 18:23:32 +08:00
|
|
|
|
//Dark
|
2024-06-10 18:05:32 +08:00
|
|
|
|
new SolidColorBrush(StringToColor("#FF555555"));
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ComboBoxFloatingBarImg.SelectedIndex = Settings.Appearance.FloatingBarImg;
|
|
|
|
|
if (ComboBoxFloatingBarImg.SelectedIndex == 0)
|
2024-05-04 18:56:19 +08:00
|
|
|
|
{
|
2024-06-10 18:05:32 +08:00
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/icc.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(0.5);
|
2024-06-04 21:21:08 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 1)
|
2024-05-04 18:56:19 +08:00
|
|
|
|
{
|
2024-06-10 18:05:32 +08:00
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/icc-transparent-dark-small.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(1.2);
|
2024-05-04 18:56:19 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 2)
|
2024-06-07 21:27:16 +08:00
|
|
|
|
{
|
2024-06-10 18:05:32 +08:00
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/kuandoujiyanhuaji.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1.5);
|
2024-06-07 21:27:16 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 3)
|
2024-06-07 21:27:16 +08:00
|
|
|
|
{
|
2024-06-10 18:05:32 +08:00
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/kuanshounvhuaji.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1.5);
|
2024-06-07 21:27:16 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 4)
|
|
|
|
|
{
|
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/kuanciya.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1.5);
|
|
|
|
|
}
|
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 5)
|
|
|
|
|
{
|
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/kuanneikuhuaji.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1.5);
|
|
|
|
|
}
|
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 6)
|
|
|
|
|
{
|
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/kuandogeyuanliangwo.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1.5);
|
|
|
|
|
}
|
|
|
|
|
else if (ComboBoxFloatingBarImg.SelectedIndex == 7)
|
|
|
|
|
{
|
|
|
|
|
FloatingbarHeadIconImg.Source =
|
|
|
|
|
new BitmapImage(new Uri("pack://application:,,,/Resources/Icons-png/tiebahuaji.png"));
|
|
|
|
|
FloatingbarHeadIconImg.Margin = new Thickness(2, 2, 2, 1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ToggleSwitchEnableTimeDisplayInWhiteboardMode.IsOn =
|
|
|
|
|
Settings.Appearance.EnableTimeDisplayInWhiteboardMode;
|
|
|
|
|
|
|
|
|
|
ToggleSwitchEnableChickenSoupInWhiteboardMode.IsOn =
|
|
|
|
|
Settings.Appearance.EnableChickenSoupInWhiteboardMode;
|
2024-06-07 21:27:16 +08:00
|
|
|
|
|
2024-05-11 01:35:32 +08:00
|
|
|
|
SystemEvents_UserPreferenceChanged(null, null);
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Appearance = new Appearance();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// PowerPointSettings
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.PowerPointSettings != null) {
|
2024-06-04 21:21:08 +08:00
|
|
|
|
PptNavigationBtn.Visibility = Settings.PowerPointSettings.IsShowPPTNavigation
|
|
|
|
|
? Visibility.Visible
|
|
|
|
|
: Visibility.Collapsed;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchShowButtonPPTNavigation.IsOn = Settings.PowerPointSettings.IsShowPPTNavigation;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
ToggleSwitchShowBottomPPTNavigationPanel.IsOn =
|
|
|
|
|
Settings.PowerPointSettings.IsShowBottomPPTNavigationPanel;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchShowSidePPTNavigationPanel.IsOn = Settings.PowerPointSettings.IsShowSidePPTNavigationPanel;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.PowerPointSettings.PowerPointSupport) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchSupportPowerPoint.IsOn = true;
|
|
|
|
|
timerCheckPPT.Start();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchSupportPowerPoint.IsOn = false;
|
|
|
|
|
timerCheckPPT.Stop();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchShowCanvasAtNewSlideShow.IsOn = Settings.PowerPointSettings.IsShowCanvasAtNewSlideShow;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerGestureInPresentationMode.IsOn =
|
|
|
|
|
Settings.PowerPointSettings.IsEnableTwoFingerGestureInPresentationMode;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableFingerGestureSlideShowControl.IsOn =
|
|
|
|
|
Settings.PowerPointSettings.IsEnableFingerGestureSlideShowControl;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoSaveStrokesInPowerPoint.IsOn =
|
|
|
|
|
Settings.PowerPointSettings.IsAutoSaveStrokesInPowerPoint;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchNotifyPreviousPage.IsOn = Settings.PowerPointSettings.IsNotifyPreviousPage;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchNotifyHiddenPage.IsOn = Settings.PowerPointSettings.IsNotifyHiddenPage;
|
2024-05-04 17:41:34 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchNotifyAutoPlayPresentation.IsOn = Settings.PowerPointSettings.IsNotifyAutoPlayPresentation;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchSupportWPS.IsOn = Settings.PowerPointSettings.IsSupportWPS;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoSaveScreenShotInPowerPoint.IsOn =
|
|
|
|
|
Settings.PowerPointSettings.IsAutoSaveScreenShotInPowerPoint;
|
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.PowerPointSettings = new PowerPointSettings();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Gesture
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Gesture != null) {
|
|
|
|
|
ToggleSwitchEnableMultiTouchMode.IsOn = Settings.Gesture.IsEnableMultiTouchMode;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerZoom.IsOn = Settings.Gesture.IsEnableTwoFingerZoom;
|
|
|
|
|
BoardToggleSwitchEnableTwoFingerZoom.IsOn = Settings.Gesture.IsEnableTwoFingerZoom;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerTranslate.IsOn = Settings.Gesture.IsEnableTwoFingerTranslate;
|
|
|
|
|
BoardToggleSwitchEnableTwoFingerTranslate.IsOn = Settings.Gesture.IsEnableTwoFingerTranslate;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerRotation.IsOn = Settings.Gesture.IsEnableTwoFingerRotation;
|
|
|
|
|
BoardToggleSwitchEnableTwoFingerRotation.IsOn = Settings.Gesture.IsEnableTwoFingerRotation;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoSwitchTwoFingerGesture.IsOn = Settings.Gesture.AutoSwitchTwoFingerGesture;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerRotation.IsOn = Settings.Gesture.IsEnableTwoFingerRotation;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerRotationOnSelection.IsOn =
|
|
|
|
|
Settings.Gesture.IsEnableTwoFingerRotationOnSelection;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Gesture.AutoSwitchTwoFingerGesture) {
|
|
|
|
|
if (Topmost) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerTranslate.IsOn = false;
|
|
|
|
|
BoardToggleSwitchEnableTwoFingerTranslate.IsOn = false;
|
|
|
|
|
Settings.Gesture.IsEnableTwoFingerTranslate = false;
|
2024-05-02 00:05:12 +08:00
|
|
|
|
if (!isInMultiTouchMode) ToggleSwitchEnableMultiTouchMode.IsOn = true;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchEnableTwoFingerTranslate.IsOn = true;
|
|
|
|
|
BoardToggleSwitchEnableTwoFingerTranslate.IsOn = true;
|
|
|
|
|
Settings.Gesture.IsEnableTwoFingerTranslate = true;
|
2024-05-02 00:05:12 +08:00
|
|
|
|
if (isInMultiTouchMode) ToggleSwitchEnableMultiTouchMode.IsOn = false;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
CheckEnableTwoFingerGestureBtnColorPrompt();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Gesture = new Gesture();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Canvas
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Canvas != null) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
drawingAttributes.Height = Settings.Canvas.InkWidth;
|
|
|
|
|
drawingAttributes.Width = Settings.Canvas.InkWidth;
|
|
|
|
|
|
|
|
|
|
InkWidthSlider.Value = Settings.Canvas.InkWidth * 2;
|
2024-05-12 14:23:50 +08:00
|
|
|
|
HighlighterWidthSlider.Value = Settings.Canvas.HighlighterWidth;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
|
|
|
|
ComboBoxHyperbolaAsymptoteOption.SelectedIndex = (int)Settings.Canvas.HyperbolaAsymptoteOption;
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Canvas.UsingWhiteboard) {
|
2024-06-07 21:27:16 +08:00
|
|
|
|
GridBackgroundCover.Background = new SolidColorBrush(Color.FromRgb(234, 235, 237));
|
|
|
|
|
WaterMarkTime.Foreground = new SolidColorBrush(Color.FromRgb(22, 41, 36));
|
|
|
|
|
WaterMarkDate.Foreground = new SolidColorBrush(Color.FromRgb(22, 41, 36));
|
|
|
|
|
BlackBoardWaterMark.Foreground = new SolidColorBrush(Color.FromRgb(22, 41, 36));
|
|
|
|
|
isUselightThemeColor = false;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-06-07 21:27:16 +08:00
|
|
|
|
GridBackgroundCover.Background = new SolidColorBrush(Color.FromRgb(22, 41, 36));
|
|
|
|
|
WaterMarkTime.Foreground = new SolidColorBrush(Color.FromRgb(234, 235, 237));
|
|
|
|
|
WaterMarkDate.Foreground = new SolidColorBrush(Color.FromRgb(234, 235, 237));
|
|
|
|
|
BlackBoardWaterMark.Foreground = new SolidColorBrush(Color.FromRgb(234, 235, 237));
|
|
|
|
|
isUselightThemeColor = true;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Canvas.IsShowCursor) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchShowCursor.IsOn = true;
|
|
|
|
|
inkCanvas.ForceCursor = true;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ToggleSwitchShowCursor.IsOn = false;
|
|
|
|
|
inkCanvas.ForceCursor = false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ComboBoxPenStyle.SelectedIndex = Settings.Canvas.InkStyle;
|
|
|
|
|
BoardComboBoxPenStyle.SelectedIndex = Settings.Canvas.InkStyle;
|
|
|
|
|
|
|
|
|
|
ComboBoxEraserSize.SelectedIndex = Settings.Canvas.EraserSize;
|
2024-05-04 10:30:21 +08:00
|
|
|
|
ComboBoxEraserSizeFloatingBar.SelectedIndex = Settings.Canvas.EraserSize;
|
2024-06-10 22:06:58 +08:00
|
|
|
|
BoardComboBoxEraserSize.SelectedIndex = Settings.Canvas.EraserSize;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchClearCanvasAndClearTimeMachine.IsOn =
|
|
|
|
|
Settings.Canvas.ClearCanvasAndClearTimeMachine == true;
|
|
|
|
|
|
|
|
|
|
switch (Settings.Canvas.EraserShapeType) {
|
|
|
|
|
case 0: {
|
|
|
|
|
double k = 1;
|
|
|
|
|
switch (Settings.Canvas.EraserSize) {
|
|
|
|
|
case 0:
|
|
|
|
|
k = 0.5;
|
|
|
|
|
break;
|
|
|
|
|
case 1:
|
|
|
|
|
k = 0.8;
|
|
|
|
|
break;
|
|
|
|
|
case 3:
|
|
|
|
|
k = 1.25;
|
|
|
|
|
break;
|
|
|
|
|
case 4:
|
|
|
|
|
k = 1.8;
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
inkCanvas.EraserShape = new EllipseStylusShape(k * 90, k * 90);
|
|
|
|
|
inkCanvas.EditingMode = InkCanvasEditingMode.None;
|
|
|
|
|
break;
|
2024-05-12 14:23:50 +08:00
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
case 1: {
|
|
|
|
|
double k = 1;
|
|
|
|
|
switch (Settings.Canvas.EraserSize) {
|
|
|
|
|
case 0:
|
|
|
|
|
k = 0.7;
|
|
|
|
|
break;
|
|
|
|
|
case 1:
|
|
|
|
|
k = 0.9;
|
|
|
|
|
break;
|
|
|
|
|
case 3:
|
|
|
|
|
k = 1.2;
|
|
|
|
|
break;
|
|
|
|
|
case 4:
|
|
|
|
|
k = 1.6;
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
inkCanvas.EraserShape = new RectangleStylusShape(k * 90 * 0.6, k * 90);
|
|
|
|
|
inkCanvas.EditingMode = InkCanvasEditingMode.None;
|
|
|
|
|
break;
|
2024-05-12 14:23:50 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
CheckEraserTypeTab();
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchHideStrokeWhenSelecting.IsOn = Settings.Canvas.HideStrokeWhenSelecting;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Canvas.FitToCurve) {
|
2024-05-04 01:01:16 +08:00
|
|
|
|
ToggleSwitchFitToCurve.IsOn = true;
|
|
|
|
|
drawingAttributes.FitToCurve = true;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-04 01:01:16 +08:00
|
|
|
|
ToggleSwitchFitToCurve.IsOn = false;
|
|
|
|
|
drawingAttributes.FitToCurve = false;
|
|
|
|
|
}
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Canvas = new Canvas();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Advanced
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Advanced != null) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
TouchMultiplierSlider.Value = Settings.Advanced.TouchMultiplier;
|
|
|
|
|
FingerModeBoundsWidthSlider.Value = Settings.Advanced.FingerModeBoundsWidth;
|
|
|
|
|
NibModeBoundsWidthSlider.Value = Settings.Advanced.NibModeBoundsWidth;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchIsLogEnabled.IsOn = Settings.Advanced.IsLogEnabled;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchIsSecondConfimeWhenShutdownApp.IsOn = Settings.Advanced.IsSecondConfirmWhenShutdownApp;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEraserBindTouchMultiplier.IsOn = Settings.Advanced.EraserBindTouchMultiplier;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchIsSpecialScreen.IsOn = Settings.Advanced.IsSpecialScreen;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
|
|
|
|
TouchMultiplierSlider.Visibility =
|
|
|
|
|
ToggleSwitchIsSpecialScreen.IsOn ? Visibility.Visible : Visibility.Collapsed;
|
2024-05-01 18:23:32 +08:00
|
|
|
|
|
|
|
|
|
ToggleSwitchIsQuadIR.IsOn = Settings.Advanced.IsQuadIR;
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Advanced = new Advanced();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// InkToShape
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.InkToShape != null) {
|
|
|
|
|
ToggleSwitchEnableInkToShape.IsOn = Settings.InkToShape.IsInkToShapeEnabled;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableInkToShapeNoFakePressureRectangle.IsOn =
|
|
|
|
|
Settings.InkToShape.IsInkToShapeNoFakePressureRectangle;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchEnableInkToShapeNoFakePressureTriangle.IsOn =
|
|
|
|
|
Settings.InkToShape.IsInkToShapeNoFakePressureTriangle;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleCheckboxEnableInkToShapeTriangle.IsChecked = Settings.InkToShape.IsInkToShapeTriangle;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleCheckboxEnableInkToShapeRectangle.IsChecked = Settings.InkToShape.IsInkToShapeRectangle;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleCheckboxEnableInkToShapeRounded.IsChecked = Settings.InkToShape.IsInkToShapeRounded;
|
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.InkToShape = new InkToShape();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// RandSettings
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.RandSettings != null) { } else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.RandSettings = new RandSettings();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// Automation
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Automation != null) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
StartOrStoptimerCheckAutoFold();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInEasiNote.IsOn = Settings.Automation.IsAutoFoldInEasiNote;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInEasiCamera.IsOn = Settings.Automation.IsAutoFoldInEasiCamera;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInEasiNote3C.IsOn = Settings.Automation.IsAutoFoldInEasiNote3C;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInEasiNote5C.IsOn = Settings.Automation.IsAutoFoldInEasiNote5C;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInSeewoPincoTeacher.IsOn = Settings.Automation.IsAutoFoldInSeewoPincoTeacher;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInHiteTouchPro.IsOn = Settings.Automation.IsAutoFoldInHiteTouchPro;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInHiteLightBoard.IsOn = Settings.Automation.IsAutoFoldInHiteLightBoard;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInHiteCamera.IsOn = Settings.Automation.IsAutoFoldInHiteCamera;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInWxBoardMain.IsOn = Settings.Automation.IsAutoFoldInWxBoardMain;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInOldZyBoard.IsOn = Settings.Automation.IsAutoFoldInOldZyBoard;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInMSWhiteboard.IsOn = Settings.Automation.IsAutoFoldInMSWhiteboard;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoFoldInPPTSlideShow.IsOn = Settings.Automation.IsAutoFoldInPPTSlideShow;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (Settings.Automation.IsAutoKillEasiNote || Settings.Automation.IsAutoKillPptService) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
timerKillProcess.Start();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
timerKillProcess.Stop();
|
|
|
|
|
}
|
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoKillEasiNote.IsOn = Settings.Automation.IsAutoKillEasiNote;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoKillHiteAnnotation.IsOn = Settings.Automation.IsAutoKillHiteAnnotation;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoKillPptService.IsOn = Settings.Automation.IsAutoKillPptService;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoSaveStrokesAtClear.IsOn = Settings.Automation.IsAutoSaveStrokesAtClear;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchSaveScreenshotsInDateFolders.IsOn = Settings.Automation.IsSaveScreenshotsInDateFolders;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-06-10 18:05:32 +08:00
|
|
|
|
ToggleSwitchAutoSaveStrokesAtScreenshot.IsOn = Settings.Automation.IsAutoSaveStrokesAtScreenshot;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
SideControlMinimumAutomationSlider.Value = Settings.Automation.MinimumAutomationStrokeNumber;
|
|
|
|
|
|
|
|
|
|
AutoSavedStrokesLocation.Text = Settings.Automation.AutoSavedStrokesLocation;
|
|
|
|
|
ToggleSwitchAutoDelSavedFiles.IsOn = Settings.Automation.AutoDelSavedFiles;
|
2024-06-04 21:21:08 +08:00
|
|
|
|
ComboBoxAutoDelSavedFilesDaysThreshold.Text =
|
|
|
|
|
Settings.Automation.AutoDelSavedFilesDaysThreshold.ToString();
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
Settings.Automation = new Automation();
|
|
|
|
|
}
|
2024-06-04 21:21:08 +08:00
|
|
|
|
|
2024-05-01 18:23:32 +08:00
|
|
|
|
// auto align
|
2024-06-10 18:05:32 +08:00
|
|
|
|
if (BtnPPTSlideShowEnd.Visibility == Visibility.Visible) {
|
2024-05-01 18:23:32 +08:00
|
|
|
|
ViewboxFloatingBarMarginAnimation(60);
|
2024-06-10 18:05:32 +08:00
|
|
|
|
} else {
|
2024-05-13 01:54:04 +08:00
|
|
|
|
ViewboxFloatingBarMarginAnimation(100, true);
|
2024-05-01 18:23:32 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|