Skip to content

Commit

Permalink
修正外掛檢查沒辦法正確的顯示結果的問題
Browse files Browse the repository at this point in the history
  • Loading branch information
SODAISpod committed Feb 27, 2021
1 parent d11511f commit 657239a
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 22 deletions.
40 changes: 20 additions & 20 deletions ChehueWPF/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,24 @@ private void ListBoxItem_Selected(object sender, RoutedEventArgs e)
}
}

public class LockableToggleButton : ListBoxItem
{
protected override void OnToggle()
{
if (!LockToggle)
{
base.OnToggle();
}
}

public bool LockToggle
{
get { return (bool)GetValue(LockToggleProperty); }
set { SetValue(LockToggleProperty, value); }
}

// Using a DependencyProperty as the backing store for LockToggle. This enables animation, styling, binding, etc...
public static readonly DependencyProperty LockToggleProperty =
DependencyProperty.Register("LockToggle", typeof(bool), typeof(LockableToggleButton), new UIPropertyMetadata(false));
}
//public class LockableToggleButton : ListBoxItem
//{
// protected override void OnToggle()
// {
// if (!LockToggle)
// {
// base.OnToggle();
// }
// }

// public bool LockToggle
// {
// get { return (bool)GetValue(LockToggleProperty); }
// set { SetValue(LockToggleProperty, value); }
// }

// // Using a DependencyProperty as the backing store for LockToggle. This enables animation, styling, binding, etc...
// public static readonly DependencyProperty LockToggleProperty =
// DependencyProperty.Register("LockToggle", typeof(bool), typeof(LockableToggleButton), new UIPropertyMetadata(false));
//}
}
2 changes: 1 addition & 1 deletion 作夥直排/Book.cs
Original file line number Diff line number Diff line change
Expand Up @@ -755,7 +755,7 @@ private void CSSEdit(string path, bool fontEmbed)
_cssstrings = css.GetCss();

//以下待修整




Expand Down
5 changes: 4 additions & 1 deletion 作夥直排/Setting.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs
}
private bool CheckCalibrePathIsValid()
{
ExtensionChecker.CheckAll();
if (!ExtensionChecker.calibreStatus)
{
CalibrePathValidResult.Text = "路徑無效!";
Expand Down Expand Up @@ -74,7 +75,7 @@ private void linkLabel4_LinkClicked(object sender, LinkLabelLinkClickedEventArgs

private bool CheckKindlegenPathIsValid()
{

ExtensionChecker.CheckAll();
if (!ExtensionChecker.kindleGenStatus)
{
KindlegenPathValidResult.Text = "路徑無效!";
Expand Down Expand Up @@ -134,6 +135,8 @@ private void linkLabel2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs

private bool CheckPandocPathIsValid()
{

ExtensionChecker.CheckAll();
if (!ExtensionChecker.pandocStatus)
{
PandocPathValidResult.Text = "路徑無效!";
Expand Down

0 comments on commit 657239a

Please sign in to comment.