Added a socket client

This commit is contained in:
Rene Schwarz
2021-08-07 01:01:17 +02:00
parent 58524a9514
commit f8f28984a5
62 changed files with 1320 additions and 174 deletions

Binary file not shown.

View File

@@ -0,0 +1,31 @@
using System;
using System.Collections.Generic;
using System.Net;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;
namespace Server_Dashboard_Socket {
/// <summary>
/// Client Socket
/// </summary>
/// <typeparam name="TProtocol">The Protocol type, either JsonMessageProtocol or XmlMessageProtocol</typeparam>
/// <typeparam name="TMessageType">The message type, either JObject or XDocument</typeparam>
public class ClientChannel<TProtocol, TMessageType> : SocketChannel<TProtocol, TMessageType>
where TProtocol : Protocol<TMessageType>, new(){
/// <summary>
/// Connect to the socket async
/// </summary>
/// <param name="endpoint">An endpoint with an IP address and port</param>
/// <returns></returns>
public async Task ConnectAsync(IPEndPoint endpoint) {
//Creates a new Socket
var socket = new Socket(endpoint.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
//Connects to the socket
await socket.ConnectAsync(endpoint).ConfigureAwait(false);
//Attach the socket to a network stream
Attach(socket);
}
}
}

View File

@@ -0,0 +1,95 @@
using System;
using System.Collections.Generic;
using System.Net.Sockets;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace Server_Dashboard_Socket {
/// <summary>
/// Generic Channel class that handles the connection and message sending / receiving
/// Inherits IDisposable to correctly cut the connection to the server
/// </summary>
/// <typeparam name="TProtocol">The Protocol type, either JsonMessageProtocol or XmlMessageProtocol</typeparam>
/// <typeparam name="TMessageType">The message type, either JObject or XDocument</typeparam>
public abstract class SocketChannel<TProtocol, TMessageType> : IDisposable
where TProtocol : Protocol<TMessageType>, new() {
protected bool isDisposable = false;
NetworkStream networkStream;
readonly CancellationTokenSource cancellationTokenSource = new CancellationTokenSource();
readonly TProtocol protocol = new TProtocol();
Func<TMessageType, Task> messageCallback;
/// <summary>
/// Attaches the socket to a network stream that owns the socket
/// if the network stream goes down it takes the socket with it!
/// </summary>
/// <param name="socket">A Socket</param>
public void Attach(Socket socket) {
networkStream = new NetworkStream(socket, true);
_ = Task.Run(ReceiveLoop, cancellationTokenSource.Token);
}
/// <summary>
/// Takes a function with a message and sets the private member to the functions value
/// </summary>
/// <param name="callbackHandler"></param>
public void OnMessage(Func<TMessageType, Task> callbackHandler) => messageCallback = callbackHandler;
/// <summary>
/// Makes sure to close the socket
/// </summary>
public void Close() {
cancellationTokenSource.Cancel();
networkStream?.Close();
}
/// <summary>
/// Sends the message async
/// </summary>
/// <typeparam name="T">Anything as message, e.g. object or string</typeparam>
/// <param name="message">The message</param>
/// <returns></returns>
public async Task SendAsync<T>(T message) => await protocol.SendAsync(networkStream, message).ConfigureAwait(false);
/// <summary>
/// Checks for received messages
/// </summary>
/// <returns>received message</returns>
protected virtual async Task ReceiveLoop() {
while (!cancellationTokenSource.Token.IsCancellationRequested) {
var msg = await protocol.ReceiveAsync(networkStream).ConfigureAwait(false);
await messageCallback(msg).ConfigureAwait(false);
}
}
/// <summary>
/// Deconstructor sets Dispose to false
/// </summary>
~SocketChannel() => Dispose(false);
/// <summary>
/// Sets dispose to true
/// </summary>
public void Dispose() => Dispose(true);
/// <summary>
/// Disposes open sockets
/// </summary>
/// <param name="isDisposing">Is it currently disposing stuff?</param>
protected void Dispose(bool isDisposing) {
//If its not disposable
if (!isDisposable) {
//Set disposable to true
isDisposable = true;
//Close the socket
Close();
//If its closed, dispose it
networkStream?.Dispose();
//Wait with the garbage collection untill the disposing is done
if (isDisposing)
GC.SuppressFinalize(this);
}
}
}
}

View File

@@ -0,0 +1,90 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Net.Sockets;
using System.Net;
using System.Threading.Tasks;
using System.IO;
using System.Xml.Serialization;
using Server_Dashboard_Socket.Protocol;
using Newtonsoft.Json.Linq;
using System.Xml.Linq;
namespace Server_Dashboard_Socket {
public class SocketClient {
public SocketClient() {
//Starts the echo server for testing purposes
EchoServer echoServer = new EchoServer();
echoServer.Start();
//Start the Socket test
Start();
}
private async void Start() {
//Creates a new endpoint with the IP adress and port
var endpoint = new IPEndPoint(IPAddress.Loopback, 9000);
//Creates a new Channel for the Json protocol
var channel = new ClientChannel<JsonMessageProtocol, JObject>();
//Creates a new Channel for the XDocument protocol
//var channel = new ClientChannel<XmlMessageProtocol, XDocument>();
//Callback for the message
channel.OnMessage(OnMessage);
//Connect to the Socket
await channel.ConnectAsync(endpoint).ConfigureAwait(false);
//Test message
var myMessage = new MyMessage {
IntProperty = 404,
StringProperty = "Hello World!"
};
//Send the test message
await channel.SendAsync(myMessage).ConfigureAwait(false);
}
/// <summary>
/// When it receives a message it gets converted from Json back to MyMessage
/// </summary>
/// <param name="jobject">The json to be converted back</param>
/// <returns>Task completed</returns>
static Task OnMessage(JObject jobject) {
Console.WriteLine(Convert(jobject));
return Task.CompletedTask;
}
/// <summary>
/// When it receives a message it gets converted from XDocument back to MyMessage
/// </summary>
/// <param name="xDocument">The xml to be converted back</param>
/// <returns>Task completed</returns>
static Task OnMessage(XDocument xDocument) {
Console.WriteLine(Convert(xDocument));
return Task.CompletedTask;
}
/// <summary>
/// Converts json to MyMessage
/// </summary>
/// <param name="jObject">The json to be converted</param>
/// <returns>MyMessage object</returns>
static MyMessage Convert(JObject jObject) => jObject.ToObject(typeof(MyMessage)) as MyMessage;
/// <summary>
/// Converts XDocument to MyMessage
/// </summary>
/// <param name="xmlDocument">The xml to be converted</param>
/// <returns>MyMessage object</returns>
static MyMessage Convert(XDocument xmlDocument) => new XmlSerializer(typeof(MyMessage)).Deserialize(new StringReader(xmlDocument.ToString())) as MyMessage;
}
/// <summary>
/// MyMessage test class
/// Delete later when Sockets are finished
/// </summary>
public class MyMessage {
public int IntProperty { get; set; }
public string StringProperty { get; set; }
}
}

View File

@@ -8,26 +8,47 @@ namespace Server_Dashboard_Socket {
/// Basic echo server to test the socket connection
/// </summary>
public class EchoServer {
public void Start(int port = 9565) {
/// <summary>
/// Start the socket on 127.0.0.1:9000
/// </summary>
/// <param name="port">A port that is not already in use</param>
public void Start(int port = 9000) {
//Creates a new endpoint on 127.0.0.1 and the port 9000
IPEndPoint endPoint = new IPEndPoint(IPAddress.Loopback, port);
//Creates a new Socket on the given endpoint
Socket socket = new Socket(endPoint.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
//Bind the endpoint to the socket
socket.Bind(endPoint);
//Define how many Clients you want to have connected max
socket.Listen(128);
//Just run the Task forever
_ = Task.Run(() => DoEcho(socket));
}
/// <summary>
/// Listens for messages and sends them back asap
/// </summary>
/// <param name="socket">The socket to work with</param>
/// <returns>poop</returns>
private async Task DoEcho(Socket socket) {
while (true) {
//Listen for incomming connection requests and accept them
Socket clientSocket = await Task.Factory.FromAsync(
new Func<AsyncCallback, object, IAsyncResult>(socket.BeginAccept),
new Func<IAsyncResult, Socket>(socket.EndAccept),
null).ConfigureAwait(false);
//Create a network stream and make it the owner of the socket
//This will close the socket if the stream is closed and vice verca
using(NetworkStream stream = new NetworkStream(clientSocket, true)) {
//New buffer for the message in bytes
byte[] buffer = new byte[1024];
while (true) {
//Read everything that somes in
int bytesRead = await stream.ReadAsync(buffer, 0, buffer.Length).ConfigureAwait(false);
//If its 0 just leave since its a obscolete connection
if (bytesRead == 0)
break;
//Send it back to the sender
await stream.WriteAsync(buffer, 0, bytesRead).ConfigureAwait(false);
}
}

View File

@@ -0,0 +1,53 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using Newtonsoft.Json.Serialization;
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace Server_Dashboard_Socket.Protocol {
/// <summary>
/// Json serializer class
/// </summary>
public class JsonMessageProtocol : Protocol<JObject> {
//The Json serializer and the settings
static readonly JsonSerializer serializer;
static readonly JsonSerializerSettings settings;
/// <summary>
/// Settings for the Json Serializer
/// </summary>
static JsonMessageProtocol() {
//Set the settings
settings = new JsonSerializerSettings {
Formatting = Formatting.Indented,
DateTimeZoneHandling = DateTimeZoneHandling.Utc,
ContractResolver = new DefaultContractResolver {
NamingStrategy = new CamelCaseNamingStrategy {
ProcessDictionaryKeys = false
}
}
};
settings.PreserveReferencesHandling = PreserveReferencesHandling.None;
//Creates the serializer with the settings
serializer = JsonSerializer.Create(settings);
}
//Decode the message, to Json
protected override JObject Decode(byte[] message) => JObject.Parse(Encoding.UTF8.GetString(message));
/// <summary>
/// Encode the body from Json to bytes
/// </summary>
/// <typeparam name="T">The message type e.g. object or string</typeparam>
/// <param name="message">The message to send</param>
/// <returns>message as byte[]</returns>
protected override byte[] EncodeBody<T>(T message) {
var sb = new StringBuilder();
var sw = new StringWriter(sb);
serializer.Serialize(sw, message);
return Encoding.UTF8.GetBytes(sb.ToString());
}
}
}

View File

@@ -0,0 +1,132 @@
using System;
using System.Collections.Generic;
using System.Net;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;
namespace Server_Dashboard_Socket {
/// <summary>
/// Generic Protocol class for Json and Xml serialization
/// </summary>
/// <typeparam name="TMessageType">JsonMessageProtocol or XmlMessageProtocol</typeparam>
public abstract class Protocol<TMessageType> {
//Header size is always 4
const int HEADER_SIZE = 4;
/// <summary>
/// Gets the message and checks with the header if the message is valid or not
/// important to defend against attacks with infinite long messages
/// </summary>
/// <param name="networkStream">A network stream</param>
/// <returns>MessageType e.g. Json or Xml</returns>
public async Task<TMessageType> ReceiveAsync(NetworkStream networkStream) {
//Gets the body length
int bodyLength = await ReadHeader(networkStream).ConfigureAwait(false);
//Validates the length
AssertValidMessageLength(bodyLength);
//Returns the body message type
return await Readbody(networkStream, bodyLength).ConfigureAwait(false);
}
/// <summary>
/// Sends data Async
/// </summary>
/// <typeparam name="T">Message type e.g. object or string</typeparam>
/// <param name="networkStream">Network stream</param>
/// <param name="message">The message</param>
/// <returns></returns>
public async Task SendAsync<T>(NetworkStream networkStream, T message) {
//encodes the message to a header and body
var (header, body) = Encode(message);
//Sends the header
await networkStream.WriteAsync(header, 0, header.Length).ConfigureAwait(false);
//Sends the body
await networkStream.WriteAsync(body, 0, body.Length).ConfigureAwait(false);
}
/// <summary>
/// Reads the header and converts it to an integer
/// </summary>
/// <param name="networkStream">A network stream</param>
/// <returns>Header as Integer</returns>
async Task<int> ReadHeader(NetworkStream networkStream) {
byte[] headerBytes = await ReadAsync(networkStream, HEADER_SIZE).ConfigureAwait(false);
return IPAddress.HostToNetworkOrder(BitConverter.ToInt32(headerBytes));
}
/// <summary>
/// Reads the body and decodes it to a human readable string
/// </summary>
/// <param name="networkStream">A network stream</param>
/// <param name="bodyLength">Length of the body</param>
/// <returns>Decoded body</returns>
async Task<TMessageType> Readbody(NetworkStream networkStream, int bodyLength) {
//Reads the bytes from the stream into an array
byte[] bodyBytes = await ReadAsync(networkStream, bodyLength).ConfigureAwait(false);
//Decodes it and returns the string
return Decode(bodyBytes);
}
/// <summary>
/// Reads the network stream as long as something is readable
/// </summary>
/// <param name="networkStream">A network stream</param>
/// <param name="bytesToRead">how many bytes there are to read</param>
/// <returns>Every byte from the Stream</returns>
async Task<byte[]> ReadAsync(NetworkStream networkStream, int bytesToRead) {
//new buffer that is as big as the content(watch out for buffer overflows)
byte[] buffer = new byte[bytesToRead];
//keep acount of the bytes that are already read
int bytesRead = 0;
//White we still have something to read
while(bytesRead < bytesToRead){
//Read it from the stream
var bytesReceived = await networkStream.ReadAsync(buffer, bytesRead, (bytesToRead - bytesRead)).ConfigureAwait(false);
//If it happens to be 0 close the socket
if (bytesReceived == 0)
throw new Exception("Socket Closed");
bytesRead += bytesReceived;
}
return buffer;
}
/// <summary>
/// Encode the message from human readable to bytes for the stream
/// </summary>
/// <typeparam name="T">The message as anything e.g. object or strng</typeparam>
/// <param name="message">The message to be send</param>
/// <returns>The Header and Body as bytes[]</returns>
protected (byte[] header, byte[] body) Encode<T>(T message) {
//Creates the body bytes
var bodyBytes = EncodeBody(message);
//Creates the header bytes
var headerBytes = BitConverter.GetBytes(IPAddress.HostToNetworkOrder(bodyBytes.Length));
return (headerBytes, bodyBytes);
}
/// <summary>
/// Decode the message with the given type, json or xml
/// </summary>
/// <param name="message">The message to decode</param>
/// <returns>Decoded message</returns>
protected abstract TMessageType Decode(byte[] message);
/// <summary>
/// Validate the message length to combat attacks
/// </summary>
/// <param name="messageLength">The message length</param>
protected virtual void AssertValidMessageLength(int messageLength) {
//If its not 0 throw an exception
if (messageLength < 1)
throw new ArgumentOutOfRangeException("Invalid message length");
}
/// <summary>
/// Encode the message so it can be send via the network stream
/// </summary>
/// <typeparam name="T">Message type e.g. object or string</typeparam>
/// <param name="message">The message to be send</param>
/// <returns></returns>
protected abstract byte[] EncodeBody<T> (T message);
}
}

View File

@@ -0,0 +1,47 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Xml;
using System.Xml.Linq;
using System.Xml.Serialization;
namespace Server_Dashboard_Socket {
/// <summary>
/// Xml serialize class
/// </summary>
public class XmlMessageProtocol : Protocol<XDocument> {
/// <summary>
/// Decodes the message from byte[] to XDocument
/// </summary>
/// <param name="message">The message to decode</param>
/// <returns>Message as XDocument</returns>
protected override XDocument Decode(byte[] message) {
//Reads the data as utf8 string
var xmlData = Encoding.UTF8.GetString(message);
//Creates a new reader
var xmlReader = XmlReader.Create(new StringReader(xmlData), new XmlReaderSettings { DtdProcessing = DtdProcessing.Ignore });
//Decodes the data to XDocument format
return XDocument.Load(xmlReader);
}
/// <summary>
/// Encode the XDocument to byte[]
/// </summary>
/// <typeparam name="T">Message type e.g. object or string</typeparam>
/// <param name="message">The message to encode</param>
/// <returns>Message as byte[]</returns>
protected override byte[] EncodeBody<T>(T message) {
//new string builder
StringBuilder sb = new StringBuilder();
//New string writer with the string builder
StringWriter sw = new StringWriter(sb);
//new xml serializer with the same type as the message
XmlSerializer xs = new XmlSerializer(typeof(T));
//Serialize the message to a regular string
xs.Serialize(sw, message);
//Return as UTF8 encoded byte array
return Encoding.UTF8.GetBytes(sb.ToString());
}
}
}

View File

@@ -5,4 +5,8 @@
<RootNamespace>Server_Dashboard_Socket</RootNamespace>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup>
</Project>

View File

@@ -7,9 +7,20 @@
"targets": {
".NETCoreApp,Version=v3.1": {
"Server Dashboard Socket/1.0.0": {
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"runtime": {
"Server Dashboard Socket.dll": {}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
@@ -18,6 +29,13 @@
"type": "project",
"serviceable": false,
"sha512": ""
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

View File

@@ -1 +1 @@
40cb88c995736b43b2440aaa34383fa2c95563ea
8966ab4db41ed1e711f8adec4e833a86df6a665c

View File

@@ -43,6 +43,12 @@
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"dependencies": {
"Newtonsoft.Json": {
"target": "Package",
"version": "[13.0.1, )"
}
},
"imports": [
"net461",
"net462",

View File

@@ -1,11 +1,51 @@
{
"version": 3,
"targets": {
".NETCoreApp,Version=v3.1": {}
".NETCoreApp,Version=v3.1": {
"Newtonsoft.Json/13.0.1": {
"type": "package",
"compile": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
},
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
}
}
}
},
"libraries": {
"Newtonsoft.Json/13.0.1": {
"sha512": "ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"type": "package",
"path": "newtonsoft.json/13.0.1",
"files": [
".nupkg.metadata",
".signature.p7s",
"LICENSE.md",
"lib/net20/Newtonsoft.Json.dll",
"lib/net20/Newtonsoft.Json.xml",
"lib/net35/Newtonsoft.Json.dll",
"lib/net35/Newtonsoft.Json.xml",
"lib/net40/Newtonsoft.Json.dll",
"lib/net40/Newtonsoft.Json.xml",
"lib/net45/Newtonsoft.Json.dll",
"lib/net45/Newtonsoft.Json.xml",
"lib/netstandard1.0/Newtonsoft.Json.dll",
"lib/netstandard1.0/Newtonsoft.Json.xml",
"lib/netstandard1.3/Newtonsoft.Json.dll",
"lib/netstandard1.3/Newtonsoft.Json.xml",
"lib/netstandard2.0/Newtonsoft.Json.dll",
"lib/netstandard2.0/Newtonsoft.Json.xml",
"newtonsoft.json.13.0.1.nupkg.sha512",
"newtonsoft.json.nuspec",
"packageIcon.png"
]
}
},
"libraries": {},
"projectFileDependencyGroups": {
".NETCoreApp,Version=v3.1": []
".NETCoreApp,Version=v3.1": [
"Newtonsoft.Json >= 13.0.1"
]
},
"packageFolders": {
"C:\\Users\\Crylia\\.nuget\\packages\\": {},
@@ -50,6 +90,12 @@
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"dependencies": {
"Newtonsoft.Json": {
"target": "Package",
"version": "[13.0.1, )"
}
},
"imports": [
"net461",
"net462",

View File

@@ -1,8 +1,10 @@
{
"version": 2,
"dgSpecHash": "TThsag+xtSY7ctBsPwAhUX7uLjuhld1ipCW1nP987HRzxMfYvczqncYfdca/U4IfbiniWP3eJFeh7yA09+/gGA==",
"dgSpecHash": "l9ApM4rx/nIquK7TUSE2VVfvhwnQ4+tycTwd5vMzM9v+MhFzGIKE8eVwCEj+r8Oe9Orh3cE/LeZlJ+t9G9ZaSg==",
"success": true,
"projectFilePath": "C:\\Users\\Crylia\\Documents\\Git\\Server Dashboard\\Server Dashboard Socket\\Server Dashboard Socket.csproj",
"expectedPackageFiles": [],
"expectedPackageFiles": [
"C:\\Users\\Crylia\\.nuget\\packages\\newtonsoft.json\\13.0.1\\newtonsoft.json.13.0.1.nupkg.sha512"
],
"logs": []
}

View File

@@ -18,10 +18,10 @@
<Compile Update="Controls\ServerModules\ServerModule.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Views\DashboardPages\MainDashboardPage.xaml.cs">
<Compile Update="Views\Pages\MainDashboardPage.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml.cs">
<Compile Update="Views\Dashboard\CRUD Popup\CreateModulePopup.xaml.cs">
<SubType>Code</SubType>
</Compile>
<Compile Update="Views\DashboardWindow.xaml.cs">
@@ -44,10 +44,10 @@
<Page Update="LoginWindow.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Views\DashboardPages\MainDashboardPage.xaml">
<Page Update="Views\Pages\MainDashboardPage.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml">
<Page Update="Views\Dashboard\CRUD Popup\CreateModulePopup.xaml">
<SubType>Designer</SubType>
</Page>
<Page Update="Views\DashboardWindow.xaml">

View File

@@ -4,6 +4,7 @@ using System.Diagnostics;
using System.Windows;
using System.Windows.Input;
using Server_Dashboard_Socket;
using System;
namespace Server_Dashboard {
/// <summary>
@@ -15,6 +16,47 @@ namespace Server_Dashboard {
#endregion
#region Properties
private string serverName;
public string ServerName {
get { return serverName; }
set {
if(serverName != value)
serverName = value;
OnPropertyChanged(nameof(serverName));
}
}
private string moduleName;
public string ModuleName {
get { return moduleName; }
set {
if (moduleName != value)
moduleName = value;
OnPropertyChanged(nameof(moduleName));
}
}
private string ipAdress;
public string IPAdress {
get { return ipAdress; }
set {
if (ipAdress != value)
ipAdress = value;
OnPropertyChanged(nameof(ipAdress));
}
}
private string port;
public string Port {
get { return port; }
set {
if (port != value)
port = value;
OnPropertyChanged(nameof(port));
}
}
//The Username displayed defaults to Username
private string userName = "Username";
public string UserName {
@@ -87,7 +129,11 @@ namespace Server_Dashboard {
/// </summary>
/// <param name="param">Nothing</param>
private void CreateModule(object param) {
if (!String.IsNullOrWhiteSpace(IPAdress)) {
} else {
//error
}
}
#endregion
}

View File

@@ -3,6 +3,7 @@ using Server_Dashboard.Properties;
using System;
using System.Windows.Input;
using System.Threading.Tasks;
using Server_Dashboard_Socket;
namespace Server_Dashboard {
/// <summary>
@@ -59,6 +60,7 @@ namespace Server_Dashboard {
#region Constructor
public LoginViewModel() {
SocketClient sc = new SocketClient();
//Loading circle is hidden on startup
Loading = "Hidden";
//Command inits

View File

@@ -50,23 +50,21 @@
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
</Grid.RowDefinitions>
<!--Server Name-->
<StackPanel VerticalAlignment="Center" Grid.Row="0" Margin="20 0 20 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="Server Name" FontSize="24" Margin="0 0 0 5">
<TextBlock Text="Module Name" FontSize="24" Margin="0 0 0 5">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.87"/>
</TextBlock.Foreground>
</TextBlock>
<TextBlock Text="*" Foreground="{StaticResource ErrorRed}" FontSize="20"/>
</StackPanel>
<Grid>
<Grid.Effect>
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
</Grid.Effect>
<TextBox Text="{Binding ServerName}" Grid.Column="1" Height="40" FontSize="20" x:Name="ServerName"/>
<TextBox Text="{Binding ModuleName}" Grid.Column="1" Height="40" FontSize="20" x:Name="ServerName"/>
<TextBlock VerticalAlignment="Center" HorizontalAlignment="Left" Text="My Awesome Server" FontSize="20" Visibility="{Binding ElementName=ServerName, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}" Grid.Column="1" IsHitTestVisible="False" Margin="5 0 0 0">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.12"/>
@@ -74,44 +72,20 @@
</TextBlock>
</Grid>
</StackPanel>
<!--Password-->
<!--Username-->
<StackPanel VerticalAlignment="Center" Grid.Row="1" Margin="20 0 20 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="Password" FontSize="24" Margin="0 0 0 5">
<TextBlock Text="Server Name" FontSize="24" Margin="0 0 0 5">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.87"/>
</TextBlock.Foreground>
</TextBlock>
<TextBlock Text="*" Foreground="{StaticResource ErrorRed}" FontSize="20"/>
</StackPanel>
<Grid>
<Grid.Effect>
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
</Grid.Effect>
<PasswordBox Width="420" VerticalAlignment="Center" HorizontalAlignment="Left" root:MonitorPasswordProperty.Value="True" Grid.Column="1" FontSize="20" x:Name="Password" Height="40">
</PasswordBox>
<TextBlock Visibility="{Binding ElementName=Password, Path=(root:HasTextProperty.Value), Converter={StaticResource UserNameVisibillity}}" x:Name="PasswordHint" Text="********" Grid.Column="1" IsHitTestVisible="False" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="5 0 0 0" FontSize="20">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.12"/>
</TextBlock.Foreground>
</TextBlock>
</Grid>
</StackPanel>
<!--Username-->
<StackPanel VerticalAlignment="Center" Grid.Row="2" Margin="20 0 20 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="Username" FontSize="24" Margin="0 0 0 5">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.87"/>
</TextBlock.Foreground>
</TextBlock>
<TextBlock Text="*" Foreground="{StaticResource ErrorRed}" FontSize="16"/>
</StackPanel>
<Grid>
<Grid.Effect>
<DropShadowEffect Direction="0" BlurRadius="5" ShadowDepth="0"/>
</Grid.Effect>
<TextBox Text="{Binding Username}" Grid.Column="1" Height="40" FontSize="20" x:Name="UserName"/>
<TextBox Text="{Binding ServerName}" Grid.Column="1" Height="40" FontSize="20" x:Name="UserName"/>
<TextBlock VerticalAlignment="Center" HorizontalAlignment="Left" Text="Name" FontSize="20" Visibility="{Binding ElementName=UserName, Path=Text.IsEmpty, Converter={StaticResource UserNameVisibillity}}" Grid.Column="1" IsHitTestVisible="False" Margin="5 0 0 0">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.12"/>
@@ -120,7 +94,7 @@
</Grid>
</StackPanel>
<!--IP Adress-->
<StackPanel VerticalAlignment="Center" Grid.Row="3" Margin="20 0 20 0">
<StackPanel VerticalAlignment="Center" Grid.Row="2" Margin="20 0 20 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="IP Adress" FontSize="24" Margin="0 0 0 5">
<TextBlock.Foreground>
@@ -142,7 +116,7 @@
</Grid>
</StackPanel>
<!--Port-->
<StackPanel VerticalAlignment="Center" Grid.Row="4" Margin="20 0 20 0">
<StackPanel VerticalAlignment="Center" Grid.Row="3" Margin="20 0 20 0">
<TextBlock Text="Port" FontSize="24" Margin="0 0 0 5">
<TextBlock.Foreground>
<SolidColorBrush Color="White" Opacity="0.87"/>

View File

@@ -33,6 +33,14 @@
}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"dependencies": {
"runtime.win-arm64.runtime.native.System.Data.SqlClient.sni": "4.4.0",
@@ -157,6 +165,9 @@
},
"System.Security.Principal.Windows/4.7.0": {},
"Server Dashboard Socket/1.0.0": {
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"runtime": {
"Server Dashboard Socket.dll": {}
}
@@ -198,6 +209,13 @@
"path": "microsoft.xaml.behaviors.wpf/1.1.31",
"hashPath": "microsoft.xaml.behaviors.wpf.1.1.31.nupkg.sha512"
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"type": "package",
"serviceable": true,

View File

@@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\..\Controls\ServerModules\ServerModule.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "12FD63773F2E25B061A0E9C5E434CAC0A984B464"
#pragma checksum "..\..\..\..\..\Controls\ServerModules\ServerModule.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "F661893245295EF9F2D7244856AFBAC10C1B3CDD"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

View File

@@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\..\Controls\ServerModules\ServerModule.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "12FD63773F2E25B061A0E9C5E434CAC0A984B464"
#pragma checksum "..\..\..\..\..\Controls\ServerModules\ServerModule.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "F661893245295EF9F2D7244856AFBAC10C1B3CDD"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

View File

@@ -1,62 +1,2 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace XamlGeneratedNamespace {
/// <summary>
/// GeneratedInternalTypeHelper
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public sealed class GeneratedInternalTypeHelper : System.Windows.Markup.InternalTypeHelper {
/// <summary>
/// CreateInstance
/// </summary>
protected override object CreateInstance(System.Type type, System.Globalization.CultureInfo culture) {
return System.Activator.CreateInstance(type, ((System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.NonPublic)
| (System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.CreateInstance)), null, null, culture);
}
/// <summary>
/// GetPropertyValue
/// </summary>
protected override object GetPropertyValue(System.Reflection.PropertyInfo propertyInfo, object target, System.Globalization.CultureInfo culture) {
return propertyInfo.GetValue(target, System.Reflection.BindingFlags.Default, null, null, culture);
}
/// <summary>
/// SetPropertyValue
/// </summary>
protected override void SetPropertyValue(System.Reflection.PropertyInfo propertyInfo, object target, object value, System.Globalization.CultureInfo culture) {
propertyInfo.SetValue(target, value, System.Reflection.BindingFlags.Default, null, null, culture);
}
/// <summary>
/// CreateDelegate
/// </summary>
protected override System.Delegate CreateDelegate(System.Type delegateType, object target, string handler) {
return ((System.Delegate)(target.GetType().InvokeMember("_CreateDelegate", (System.Reflection.BindingFlags.InvokeMethod
| (System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance)), null, target, new object[] {
delegateType,
handler}, null)));
}
/// <summary>
/// AddEventHandler
/// </summary>
protected override void AddEventHandler(System.Reflection.EventInfo eventInfo, object target, System.Delegate handler) {
eventInfo.AddEventHandler(target, handler);
}
}
}

View File

@@ -1 +1 @@
175b43d009fc01852a21c7bd83bfe66423f7f332
5650ef8dc53926fe9999328f064c0571292b9a8c

View File

@@ -27,10 +27,6 @@ C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcor
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Microsoft.Xaml.Behaviors.dll
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\GeneratedInternalTypeHelper.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Server Dashboard.dll.config
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardPages\MainDashboardPage.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardPages\MainDashboardPage.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardWindow.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardWindow.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\SharpVectors.Converters.Wpf.dll
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\SharpVectors.Core.dll
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\SharpVectors.Css.dll
@@ -43,8 +39,6 @@ C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcor
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\SshNet.Security.Cryptography.dll
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\ServerModules\ServerModule.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\ServerModules\ServerModule.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\Dashboard\CRUD Popup\CreateModulePopup.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\Dashboard\CRUD Popup\CreateModulePopup.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Microsoft.Expression.Drawing.dll
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Microsoft.Expression.Drawing.xml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Server Dashboard.csprojAssemblyReference.cache
@@ -56,3 +50,10 @@ C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcor
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Server Dashboard Socket.pdb
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\LoadingIndicator\LoadingIndicator.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Controls\LoadingIndicator\LoadingIndicator.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\Dashboard\CRUD Popup\CreateModulePopup.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\Dashboard\CRUD Popup\CreateModulePopup.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardWindow.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\Pages\MainDashboardPage.g.cs
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\DashboardWindow.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\Views\Pages\MainDashboardPage.baml
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\bin\Debug\netcoreapp3.1\Newtonsoft.Json.dll

View File

@@ -41,6 +41,14 @@
}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"dependencies": {
"runtime.win-arm64.runtime.native.System.Data.SqlClient.sni": "4.4.0",
@@ -223,6 +231,13 @@
"path": "microsoft.xaml.behaviors.wpf/1.1.31",
"hashPath": "microsoft.xaml.behaviors.wpf.1.1.31.nupkg.sha512"
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"type": "package",
"serviceable": true,

View File

@@ -10,11 +10,11 @@ none
false
TRACE;DEBUG;NETCOREAPP;NETCOREAPP3_1;
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\App.xaml
8-130641097
8-2121814096
28-605069555
2061472260849
Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml;Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;Controls\LoadingIndicator\LoadingIndicator.xaml;Controls\ServerModules\ServerModule.xaml;LoginWindow.xaml;Views\DashboardPages\MainDashboardPage.xaml;Views\DashboardWindow.xaml;
281915380331
207-679868162
Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;Controls\LoadingIndicator\LoadingIndicator.xaml;Controls\ServerModules\ServerModule.xaml;LoginWindow.xaml;Views\DashboardWindow.xaml;Views\Dashboard\CRUD Popup\CreateModulePopup.xaml;Views\Pages\MainDashboardPage.xaml;
False

View File

@@ -10,11 +10,11 @@ none
false
TRACE;DEBUG;NETCOREAPP;NETCOREAPP3_1;
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\App.xaml
8-130641097
8-2121814096
302090570471
2061472260849
Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml;Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;Controls\LoadingIndicator\LoadingIndicator.xaml;Controls\ServerModules\ServerModule.xaml;LoginWindow.xaml;Views\DashboardPages\MainDashboardPage.xaml;Views\DashboardWindow.xaml;
30316053061
207-679868162
Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;Controls\LoadingIndicator\LoadingIndicator.xaml;Controls\ServerModules\ServerModule.xaml;LoginWindow.xaml;Views\DashboardWindow.xaml;Views\Dashboard\CRUD Popup\CreateModulePopup.xaml;Views\Pages\MainDashboardPage.xaml;
True

View File

@@ -1,11 +1,11 @@
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\GeneratedInternalTypeHelper.g.i.cs
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\App.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\LoadingIndicator\LoadingIndicator.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\ServerModules\ServerModule.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\LoginWindow.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\DashboardPages\MainDashboardPage.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\DashboardWindow.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\Pages\MainDashboardPage.xaml;;

View File

@@ -1,11 +1,11 @@
C:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\obj\Debug\netcoreapp3.1\GeneratedInternalTypeHelper.g.cs
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\App.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\DoubleRoundProgressBar\DoubleRoundProgressBar.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\HalfRoundProgressBar\HalfRoundProgressBar.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\LoadingIndicator\LoadingIndicator.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Controls\ServerModules\ServerModule.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\LoginWindow.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\DashboardPages\MainDashboardPage.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\DashboardWindow.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml;;
FC:\Users\Crylia\Documents\Git\Server Dashboard\Server Dashboard\Views\Pages\MainDashboardPage.xaml;;

View File

@@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "F45F1E4243C66B9FD96C035A50A8EE4E1CBFCB34"
#pragma checksum "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "DA61FA39EA7EAD147334D5DB2BC05F3B7D1BB38C"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@@ -48,7 +48,7 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
public partial class CreateModulePopup : System.Windows.Window, System.Windows.Markup.IComponentConnector {
#line 69 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
#line 67 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox ServerName;
@@ -56,23 +56,7 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
#line hidden
#line 91 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.PasswordBox Password;
#line default
#line hidden
#line 93 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBlock PasswordHint;
#line default
#line hidden
#line 114 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
#line 88 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox UserName;
@@ -80,7 +64,7 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
#line hidden
#line 136 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
#line 110 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox IPAdress;
@@ -88,7 +72,7 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
#line hidden
#line 155 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
#line 129 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox Port;
@@ -107,23 +91,15 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/controls/dashboard/crud%20popup/createmodulepopup.xam" +
"l", System.UriKind.Relative);
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/dashboard/crud%20popup/createmodulepopup.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\..\Controls\Dashboard\CRUD Popup\CreateModulePopup.xaml"
#line 1 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal System.Delegate _CreateDelegate(System.Type delegateType, string handler) {
return System.Delegate.CreateDelegate(delegateType, this, handler);
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
@@ -137,18 +113,12 @@ namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
this.ServerName = ((System.Windows.Controls.TextBox)(target));
return;
case 2:
this.Password = ((System.Windows.Controls.PasswordBox)(target));
return;
case 3:
this.PasswordHint = ((System.Windows.Controls.TextBlock)(target));
return;
case 4:
this.UserName = ((System.Windows.Controls.TextBox)(target));
return;
case 5:
case 3:
this.IPAdress = ((System.Windows.Controls.TextBox)(target));
return;
case 6:
case 4:
this.Port = ((System.Windows.Controls.TextBox)(target));
return;
}

View File

@@ -0,0 +1,129 @@
#pragma checksum "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "DA61FA39EA7EAD147334D5DB2BC05F3B7D1BB38C"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Microsoft.Xaml.Behaviors;
using Microsoft.Xaml.Behaviors.Core;
using Microsoft.Xaml.Behaviors.Input;
using Microsoft.Xaml.Behaviors.Layout;
using Microsoft.Xaml.Behaviors.Media;
using Server_Dashboard;
using Server_Dashboard.Views.DashboardPages.ModuleCRUD;
using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Controls.Ribbon;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Media.Imaging;
using System.Windows.Media.Media3D;
using System.Windows.Media.TextFormatting;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Shell;
namespace Server_Dashboard.Views.DashboardPages.ModuleCRUD {
/// <summary>
/// CreateModulePopup
/// </summary>
public partial class CreateModulePopup : System.Windows.Window, System.Windows.Markup.IComponentConnector {
#line 67 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox ServerName;
#line default
#line hidden
#line 88 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox UserName;
#line default
#line hidden
#line 110 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox IPAdress;
#line default
#line hidden
#line 129 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox Port;
#line default
#line hidden
private bool _contentLoaded;
/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
public void InitializeComponent() {
if (_contentLoaded) {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/dashboard/crud%20popup/createmodulepopup.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\..\Views\Dashboard\CRUD Popup\CreateModulePopup.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
switch (connectionId)
{
case 1:
this.ServerName = ((System.Windows.Controls.TextBox)(target));
return;
case 2:
this.UserName = ((System.Windows.Controls.TextBox)(target));
return;
case 3:
this.IPAdress = ((System.Windows.Controls.TextBox)(target));
return;
case 4:
this.Port = ((System.Windows.Controls.TextBox)(target));
return;
}
this._contentLoaded = true;
}
}
}

View File

@@ -0,0 +1,121 @@
#pragma checksum "..\..\..\..\..\..\Views\Dashboard\DashboardPages\MainDashboardPage.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "47F667437FD33C591010E2D8FB596082CE45DAC4"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Microsoft.Xaml.Behaviors;
using Microsoft.Xaml.Behaviors.Core;
using Microsoft.Xaml.Behaviors.Input;
using Microsoft.Xaml.Behaviors.Layout;
using Microsoft.Xaml.Behaviors.Media;
using Server_Dashboard;
using Server_Dashboard.Controls.ServerModules;
using Server_Dashboard.Views.DashboardPages;
using Server_Dashboard.Views.DashboardPages.ModuleCRUD;
using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Controls.Ribbon;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Media.Imaging;
using System.Windows.Media.Media3D;
using System.Windows.Media.TextFormatting;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Shell;
namespace Server_Dashboard.Views.DashboardPages {
/// <summary>
/// MainDashboardPage
/// </summary>
public partial class MainDashboardPage : System.Windows.Controls.UserControl, System.Windows.Markup.IComponentConnector {
#line 30 "..\..\..\..\..\..\Views\Dashboard\DashboardPages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button CreateModule;
#line default
#line hidden
#line 31 "..\..\..\..\..\..\Views\Dashboard\DashboardPages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button RemoveModule;
#line default
#line hidden
#line 32 "..\..\..\..\..\..\Views\Dashboard\DashboardPages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button ChangeModule;
#line default
#line hidden
private bool _contentLoaded;
/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
public void InitializeComponent() {
if (_contentLoaded) {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;V1.0.0.0;component/views/dashboard/dashboardpages/maindashboard" +
"page.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\..\Views\Dashboard\DashboardPages\MainDashboardPage.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
switch (connectionId)
{
case 1:
this.CreateModule = ((System.Windows.Controls.Button)(target));
return;
case 2:
this.RemoveModule = ((System.Windows.Controls.Button)(target));
return;
case 3:
this.ChangeModule = ((System.Windows.Controls.Button)(target));
return;
}
this._contentLoaded = true;
}
}
}

View File

@@ -0,0 +1,98 @@
#pragma checksum "..\..\..\..\..\Views\Dashboard\DashboardWindow.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "34F9F280B2CC5ECBFCC6EA0C5845A4B16E3447E7"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Microsoft.Xaml.Behaviors;
using Microsoft.Xaml.Behaviors.Core;
using Microsoft.Xaml.Behaviors.Input;
using Microsoft.Xaml.Behaviors.Layout;
using Microsoft.Xaml.Behaviors.Media;
using Server_Dashboard;
using Server_Dashboard.Views;
using Server_Dashboard.Views.DashboardPages;
using SharpVectors.Converters;
using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Controls.Ribbon;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Media.Imaging;
using System.Windows.Media.Media3D;
using System.Windows.Media.TextFormatting;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Shell;
namespace Server_Dashboard.Views {
/// <summary>
/// DashboardWindow
/// </summary>
public partial class DashboardWindow : System.Windows.Window, System.Windows.Markup.IComponentConnector {
#line 46 "..\..\..\..\..\Views\Dashboard\DashboardWindow.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Grid TopBarGrid;
#line default
#line hidden
private bool _contentLoaded;
/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
public void InitializeComponent() {
if (_contentLoaded) {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/dashboard/dashboardwindow.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\Views\Dashboard\DashboardWindow.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
switch (connectionId)
{
case 1:
this.TopBarGrid = ((System.Windows.Controls.Grid)(target));
return;
}
this._contentLoaded = true;
}
}
}

View File

@@ -0,0 +1,121 @@
#pragma checksum "..\..\..\..\..\..\Views\Dashboard\Pages\MainDashboardPage.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "47F667437FD33C591010E2D8FB596082CE45DAC4"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Microsoft.Xaml.Behaviors;
using Microsoft.Xaml.Behaviors.Core;
using Microsoft.Xaml.Behaviors.Input;
using Microsoft.Xaml.Behaviors.Layout;
using Microsoft.Xaml.Behaviors.Media;
using Server_Dashboard;
using Server_Dashboard.Controls.ServerModules;
using Server_Dashboard.Views.DashboardPages;
using Server_Dashboard.Views.DashboardPages.ModuleCRUD;
using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Controls.Ribbon;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Media.Imaging;
using System.Windows.Media.Media3D;
using System.Windows.Media.TextFormatting;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Shell;
namespace Server_Dashboard.Views.DashboardPages {
/// <summary>
/// MainDashboardPage
/// </summary>
public partial class MainDashboardPage : System.Windows.Controls.UserControl, System.Windows.Markup.IComponentConnector {
#line 30 "..\..\..\..\..\..\Views\Dashboard\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button CreateModule;
#line default
#line hidden
#line 31 "..\..\..\..\..\..\Views\Dashboard\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button RemoveModule;
#line default
#line hidden
#line 32 "..\..\..\..\..\..\Views\Dashboard\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button ChangeModule;
#line default
#line hidden
private bool _contentLoaded;
/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
public void InitializeComponent() {
if (_contentLoaded) {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;V1.0.0.0;component/views/dashboard/pages/maindashboardpage.xaml" +
"", System.UriKind.Relative);
#line 1 "..\..\..\..\..\..\Views\Dashboard\Pages\MainDashboardPage.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
switch (connectionId)
{
case 1:
this.CreateModule = ((System.Windows.Controls.Button)(target));
return;
case 2:
this.RemoveModule = ((System.Windows.Controls.Button)(target));
return;
case 3:
this.ChangeModule = ((System.Windows.Controls.Button)(target));
return;
}
this._contentLoaded = true;
}
}
}

View File

@@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\..\Views\DashboardPages\MainDashboardPage.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "47F667437FD33C591010E2D8FB596082CE45DAC4"
#pragma checksum "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "47F667437FD33C591010E2D8FB596082CE45DAC4"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@@ -50,7 +50,7 @@ namespace Server_Dashboard.Views.DashboardPages {
public partial class MainDashboardPage : System.Windows.Controls.UserControl, System.Windows.Markup.IComponentConnector {
#line 30 "..\..\..\..\..\Views\DashboardPages\MainDashboardPage.xaml"
#line 30 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button CreateModule;
@@ -58,7 +58,7 @@ namespace Server_Dashboard.Views.DashboardPages {
#line hidden
#line 31 "..\..\..\..\..\Views\DashboardPages\MainDashboardPage.xaml"
#line 31 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button RemoveModule;
@@ -66,7 +66,7 @@ namespace Server_Dashboard.Views.DashboardPages {
#line hidden
#line 32 "..\..\..\..\..\Views\DashboardPages\MainDashboardPage.xaml"
#line 32 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button ChangeModule;
@@ -85,9 +85,9 @@ namespace Server_Dashboard.Views.DashboardPages {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/dashboardpages/maindashboardpage.xaml", System.UriKind.Relative);
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/pages/maindashboardpage.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\Views\DashboardPages\MainDashboardPage.xaml"
#line 1 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default

View File

@@ -0,0 +1,120 @@
#pragma checksum "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "47F667437FD33C591010E2D8FB596082CE45DAC4"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Microsoft.Xaml.Behaviors;
using Microsoft.Xaml.Behaviors.Core;
using Microsoft.Xaml.Behaviors.Input;
using Microsoft.Xaml.Behaviors.Layout;
using Microsoft.Xaml.Behaviors.Media;
using Server_Dashboard;
using Server_Dashboard.Controls.ServerModules;
using Server_Dashboard.Views.DashboardPages;
using Server_Dashboard.Views.DashboardPages.ModuleCRUD;
using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Controls.Ribbon;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Media.Imaging;
using System.Windows.Media.Media3D;
using System.Windows.Media.TextFormatting;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Shell;
namespace Server_Dashboard.Views.DashboardPages {
/// <summary>
/// MainDashboardPage
/// </summary>
public partial class MainDashboardPage : System.Windows.Controls.UserControl, System.Windows.Markup.IComponentConnector {
#line 30 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button CreateModule;
#line default
#line hidden
#line 31 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button RemoveModule;
#line default
#line hidden
#line 32 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button ChangeModule;
#line default
#line hidden
private bool _contentLoaded;
/// <summary>
/// InitializeComponent
/// </summary>
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
public void InitializeComponent() {
if (_contentLoaded) {
return;
}
_contentLoaded = true;
System.Uri resourceLocater = new System.Uri("/Server Dashboard;component/views/pages/maindashboardpage.xaml", System.UriKind.Relative);
#line 1 "..\..\..\..\..\Views\Pages\MainDashboardPage.xaml"
System.Windows.Application.LoadComponent(this, resourceLocater);
#line default
#line hidden
}
[System.Diagnostics.DebuggerNonUserCodeAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "5.0.4.0")]
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")]
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")]
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
switch (connectionId)
{
case 1:
this.CreateModule = ((System.Windows.Controls.Button)(target));
return;
case 2:
this.RemoveModule = ((System.Windows.Controls.Button)(target));
return;
case 3:
this.ChangeModule = ((System.Windows.Controls.Button)(target));
return;
}
this._contentLoaded = true;
}
}
}

View File

@@ -43,6 +43,12 @@
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"dependencies": {
"Newtonsoft.Json": {
"target": "Package",
"version": "[13.0.1, )"
}
},
"imports": [
"net461",
"net462",

View File

@@ -46,6 +46,15 @@
"Microsoft.WindowsDesktop.App.WPF"
]
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"compile": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
},
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
}
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"type": "package",
"dependencies": {
@@ -190,6 +199,9 @@
"Server Dashboard Socket/1.0.0": {
"type": "project",
"framework": ".NETCoreApp,Version=v3.1",
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"compile": {
"bin/placeholder/Server Dashboard Socket.dll": {}
},
@@ -289,6 +301,33 @@
"tools/Install.ps1"
]
},
"Newtonsoft.Json/13.0.1": {
"sha512": "ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"type": "package",
"path": "newtonsoft.json/13.0.1",
"files": [
".nupkg.metadata",
".signature.p7s",
"LICENSE.md",
"lib/net20/Newtonsoft.Json.dll",
"lib/net20/Newtonsoft.Json.xml",
"lib/net35/Newtonsoft.Json.dll",
"lib/net35/Newtonsoft.Json.xml",
"lib/net40/Newtonsoft.Json.dll",
"lib/net40/Newtonsoft.Json.xml",
"lib/net45/Newtonsoft.Json.dll",
"lib/net45/Newtonsoft.Json.xml",
"lib/netstandard1.0/Newtonsoft.Json.dll",
"lib/netstandard1.0/Newtonsoft.Json.xml",
"lib/netstandard1.3/Newtonsoft.Json.dll",
"lib/netstandard1.3/Newtonsoft.Json.xml",
"lib/netstandard2.0/Newtonsoft.Json.dll",
"lib/netstandard2.0/Newtonsoft.Json.xml",
"newtonsoft.json.13.0.1.nupkg.sha512",
"newtonsoft.json.nuspec",
"packageIcon.png"
]
},
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
"sha512": "9kyFSIdN3T0qjDQ2R0HRXYIhS3l5psBzQi6qqhdLz+SzFyEy4sVxNOke+yyYv8Cu8rPER12c3RDjLT8wF3WBYQ==",
"type": "package",

View File

@@ -1,12 +1,13 @@
{
"version": 2,
"dgSpecHash": "HXRDkeOq6+C/ByDU4F1SMIP1JghG7OjBlyJpDMYJu2MsBWBCCGqu1D1TkY9/AYS2Wb1ebiR2JrXDxpATbPuPhQ==",
"dgSpecHash": "OVdQd9pph1Mmk8qJsgfEA704C8zVW4BE4odMLtHpVAh7jU4dEOT0sHfeITNMhhBnGYOThv0s299Zt93V6VYmzg==",
"success": true,
"projectFilePath": "C:\\Users\\Crylia\\Documents\\Git\\Server Dashboard\\Server Dashboard\\Server Dashboard.csproj",
"expectedPackageFiles": [
"C:\\Users\\Crylia\\.nuget\\packages\\microsoft.netcore.platforms\\3.1.0\\microsoft.netcore.platforms.3.1.0.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\microsoft.win32.registry\\4.7.0\\microsoft.win32.registry.4.7.0.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\microsoft.xaml.behaviors.wpf\\1.1.31\\microsoft.xaml.behaviors.wpf.1.1.31.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\newtonsoft.json\\13.0.1\\newtonsoft.json.13.0.1.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\runtime.native.system.data.sqlclient.sni\\4.7.0\\runtime.native.system.data.sqlclient.sni.4.7.0.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\runtime.win-arm64.runtime.native.system.data.sqlclient.sni\\4.4.0\\runtime.win-arm64.runtime.native.system.data.sqlclient.sni.4.4.0.nupkg.sha512",
"C:\\Users\\Crylia\\.nuget\\packages\\runtime.win-x64.runtime.native.system.data.sqlclient.sni\\4.4.0\\runtime.win-x64.runtime.native.system.data.sqlclient.sni.4.4.0.nupkg.sha512",