applying new struckture and working vlc

This commit is contained in:
Elias Quinn
2025-06-12 14:34:51 +01:00
parent c8906c1471
commit afe5d2f5ff
75 changed files with 1045 additions and 613 deletions

View File

@@ -0,0 +1,43 @@
using System;
using System.Collections.Generic;
//namespace Scheckenrennen_GUI.modules
//Quinn Grafe Schnecken rennen
namespace ShadowStream.LogHelper
{
public class LogHelper
{
private List<string> logEntries;
public LogHelper()
{
logEntries = new List<string>();
}
public void Log(string entry)
{
AddEntry($"[{DateTime.Now:HH:mm:ss}] [INFO ] {entry}");
}
public void Warn(string entry)
{
AddEntry($"[{DateTime.Now:HH:mm:ss}] [WARN ] {entry}");
}
public void Error(string entry)
{
AddEntry($"[{DateTime.Now:HH:mm:ss}] [ERROR] {entry}");
}
private void AddEntry(string entry)
{
logEntries.Add(entry);
}
public List<string> GetEntries()
{
return logEntries;
}
}
}

View File

@@ -0,0 +1,19 @@
<!-- Quinn Grafe Schencken rennen -->
<Window x:Class="ModuleManager.LogWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
Title="LogWindow" Height="450" Width="800">
<Grid>
<TextBox x:Name="LogBox"
Foreground="Gray"
Background="Black"
FontFamily="Consolas"
IsReadOnly="True"
VerticalScrollBarVisibility="Auto"
TextWrapping="Wrap"
AcceptsReturn="True" />
</Grid>
</Window>

View File

@@ -0,0 +1,24 @@
using System;
using System.Collections.Generic;
using System.Windows;
namespace ModuleManager
{
public partial class LogWindow : Window
{
public LogWindow(List<string> logText)
{
InitializeComponent();
foreach (var s in logText)
{
LogBox.Text += s + Environment.NewLine;
}
}
public void AddLogEntry(string logEntry)
{
LogBox.Text += logEntry + Environment.NewLine;
LogBox.ScrollToEnd();
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB