-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
过滤器 选项卡右键支持:关闭、移动、固定操作 【二、优化修复】 修复输入备注时默认值不正确 完善日志系统 点击关闭后鼠标 arrow 获得焦点的时候不滚动 去掉2 个设置项:搜索时滚动、停止搜索后不滚动 去掉固定时提示关闭搜索 超大报文挂机,内存泄漏问题 menuitem 切换皮肤时未切换 优化 Tilte 菜单栏
- Loading branch information
SuperStudio
committed
Feb 5, 2023
1 parent
bb9a22f
commit 31a3c0b
Showing
23 changed files
with
677 additions
and
387 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,32 @@ | ||
using SuperUtils.Framework.Logger; | ||
using SuperUtils.IO; | ||
using SuperUtils.Time; | ||
using System; | ||
using System.IO; | ||
|
||
namespace SuperCom.Log | ||
{ | ||
public class Logger : AbstractLogger | ||
{ | ||
public static string FilePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "app.log"); | ||
private static string LogDir = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "app_logs"); | ||
private static string LogFilePath = Path.Combine(LogDir, "app.log"); | ||
private Logger() { } | ||
|
||
public static Logger Instance { get; } | ||
|
||
static Logger() | ||
{ | ||
Instance = new Logger(); | ||
Instance.LogLevel = AbstractLogger.Level.Info; | ||
if (!Directory.Exists(LogDir)) | ||
DirHelper.TryCreateDirectory(LogDir); | ||
LogFilePath = Path.Combine(LogDir, $"{DateHelper.NowDate()}.log"); | ||
} | ||
|
||
public override void LogPrint(string str) | ||
{ | ||
Console.WriteLine(str); | ||
FileHelper.TryAppendToFile(FilePath, str); | ||
FileHelper.TryAppendToFile(LogFilePath, str, System.Text.Encoding.UTF8); | ||
} | ||
} | ||
} |
Oops, something went wrong.