Beispiel #1
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            DebugLogConfig config = ConfigManager.Config.Debug.DebugLog;

            RestoreLocation(config.WindowLocation, config.WindowSize);
            UpdateLog();
        }
Beispiel #2
0
        protected override void OnFormClosing(FormClosingEventArgs e)
        {
            base.OnFormClosing(e);

            DebugLogConfig config = ConfigManager.Config.Debug.DebugLog;

            config.WindowSize     = this.WindowState != FormWindowState.Normal ? this.RestoreBounds.Size : this.Size;
            config.WindowLocation = this.WindowState != FormWindowState.Normal ? this.RestoreBounds.Location : this.Location;
            ConfigManager.ApplyChanges();
        }
Beispiel #3
0
 private static object GetLogMessage(object message)
 {
     if (_logConfig == null)
     {
         _logConfig = XCore.GetMainInstance().Services.Get <IXILRuntime>().DebugLogConfig;
     }
     if (_logConfig.EnablePrefix)
     {
         return($"{_logConfig.PrefixText}{message}");
     }
     else
     {
         return(message);
     }
 }