From 937171996aa7e253c7622507f8f7cc7987a4f5c2 Mon Sep 17 00:00:00 2001 From: kimw Date: Sun, 10 Jan 2016 05:22:20 +0800 Subject: [PATCH] name the variable better: rename LogFile => LogFilePath --- shadowsocks-csharp/Controller/Logging.cs | 6 +++--- shadowsocks-csharp/View/MenuViewController.cs | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/shadowsocks-csharp/Controller/Logging.cs b/shadowsocks-csharp/Controller/Logging.cs index 38201660..1f027a6b 100755 --- a/shadowsocks-csharp/Controller/Logging.cs +++ b/shadowsocks-csharp/Controller/Logging.cs @@ -9,14 +9,14 @@ namespace Shadowsocks.Controller { public class Logging { - public static string LogFile; + public static string LogFilePath; public static bool OpenLogFile() { try { - LogFile = Utils.GetTempPath("shadowsocks.log"); - FileStream fs = new FileStream(LogFile, FileMode.Append); + LogFilePath = Utils.GetTempPath("shadowsocks.log"); + FileStream fs = new FileStream(LogFilePath, FileMode.Append); StreamWriterWithTimestamp sw = new StreamWriterWithTimestamp(fs); sw.AutoFlush = true; Console.SetOut(sw); diff --git a/shadowsocks-csharp/View/MenuViewController.cs b/shadowsocks-csharp/View/MenuViewController.cs index 25a3b3e8..435f55ca 100755 --- a/shadowsocks-csharp/View/MenuViewController.cs +++ b/shadowsocks-csharp/View/MenuViewController.cs @@ -341,7 +341,6 @@ namespace Shadowsocks.View { item.Checked = true; } - } } @@ -363,7 +362,7 @@ namespace Shadowsocks.View { if (logForms.Count == 0) { - LogForm f = new LogForm(controller, Logging.LogFile); + LogForm f = new LogForm(controller, Logging.LogFilePath); f.Show(); f.FormClosed += logForm_FormClosed; @@ -491,7 +490,7 @@ namespace Shadowsocks.View private void ShowLogItem_Click(object sender, EventArgs e) { - LogForm f = new LogForm(controller, Logging.LogFile); + LogForm f = new LogForm(controller, Logging.LogFilePath); f.Show(); f.FormClosed += logForm_FormClosed;