Code clean

This commit is contained in:
2dust 2023-04-16 20:45:47 +08:00
parent bf6dcdf2bd
commit 6e8a3a4867
2 changed files with 7 additions and 7 deletions

View file

@ -371,19 +371,19 @@ namespace v2rayN
long TBs = GBs / factor; long TBs = GBs / factor;
if (TBs > 0) if (TBs > 0)
{ {
result = TBs + (GBs % factor / (factor + 0.0)); result = TBs + ((GBs % factor) / (factor + 0.0));
unit = "TB"; unit = "TB";
return; return;
} }
result = GBs + (MBs % factor / (factor + 0.0)); result = GBs + ((MBs % factor) / (factor + 0.0));
unit = "GB"; unit = "GB";
return; return;
} }
result = MBs + (KBs % factor / (factor + 0.0)); result = MBs + ((KBs % factor) / (factor + 0.0));
unit = "MB"; unit = "MB";
return; return;
} }
result = KBs + (amount % factor / (factor + 0.0)); result = KBs + ((amount % factor) / (factor + 0.0));
unit = "KB"; unit = "KB";
return; return;
} }

View file

@ -1424,7 +1424,7 @@ namespace v2rayN.ViewModels
{ {
MyAppExit(false); MyAppExit(false);
} }
}; }
(new UpdateHandle()).CheckUpdateGuiN(_config, _updateUI, _config.guiItem.checkPreReleaseUpdate); (new UpdateHandle()).CheckUpdateGuiN(_config, _updateUI, _config.guiItem.checkPreReleaseUpdate);
} }
@ -1453,7 +1453,7 @@ namespace v2rayN.ViewModels
File.Delete(fileName); File.Delete(fileName);
} }
} }
}; }
(new UpdateHandle()).CheckUpdateCore(type, _config, _updateUI, _config.guiItem.checkPreReleaseUpdate); (new UpdateHandle()).CheckUpdateCore(type, _config, _updateUI, _config.guiItem.checkPreReleaseUpdate);
} }
@ -1660,7 +1660,7 @@ namespace v2rayN.ViewModels
//Application.Current.MainWindow.ShowInTaskbar = false; //Application.Current.MainWindow.ShowInTaskbar = false;
//IntPtr windowHandle = new WindowInteropHelper(Application.Current.MainWindow).Handle; //IntPtr windowHandle = new WindowInteropHelper(Application.Current.MainWindow).Handle;
//Utils.RegWriteValue(Global.MyRegPath, Utils.WindowHwndKey, Convert.ToString((long)windowHandle)); //Utils.RegWriteValue(Global.MyRegPath, Utils.WindowHwndKey, Convert.ToString((long)windowHandle));
}; }
Global.ShowInTaskbar = bl; Global.ShowInTaskbar = bl;
} }