using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.IO; using System.Linq; using System.Net.NetworkInformation; using System.Runtime.InteropServices; using System.Threading; using System.Threading.Tasks; using System.Timers; using System.Windows.Forms; using System.Net; using System.Security.Principal; using System.Management; using System.Diagnostics; using System.Text; using System.Reflection; using System.Deployment.Application; namespace Dashboard { public partial class Form1 : Form { private bool dragging = false; private Point startPoint = new Point(0, 0); public static object Button { get; internal set; } [DllImport("Gdi32.dll", EntryPoint = "CreateRoundRectRgn")] private static extern IntPtr CreateRoundRectRgn ( int nLeftRect, int nTopRect, int nRightRect, int nBottomRect, int nWidthEllipse, int nHeightEllipse ); public Form1() { InitializeComponent(); Region = System.Drawing.Region.FromHrgn(CreateRoundRectRgn(0, 0, Width, Height, 25, 25)); pnlNav.Height = btnDashbord.Height; pnlNav.Top = btnDashbord.Top; pnlNav.Left = btnDashbord.Left; lbltitle.Text = "Difficult-Knights Launcher"; frmDashboard frmDashboard_vrb = new frmDashboard() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmDashboard_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmDashboard_vrb); frmDashboard_vrb.Show(); } private void Form1_Load(object sender, EventArgs e) { label1.Text = DateTime.Now.ToLongTimeString(); label2.Text = DateTime.Now.ToLongDateString(); } private void btnDashbord_Click(object sender, EventArgs e) { pnlNav.Height = btnDashbord.Height; pnlNav.Top = btnDashbord.Top; pnlNav.Left = btnDashbord.Left; btnDashbord.BackColor = Color.FromArgb(46, 51, 73); lbltitle.Text = "Difficult-Knights Launcher"; this.pnlFormLoader.Controls.Clear(); frmDashboard frmDashboard_vrb = new frmDashboard() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmDashboard_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmDashboard_vrb); frmDashboard_vrb.Show(); } private void webseite_Click(object sender, EventArgs e) { pnlNav.Height = btnAnalytics.Height; pnlNav.Top = btnAnalytics.Top; btnAnalytics.BackColor = Color.FromArgb(46, 51, 73); System.Diagnostics.Process.Start("https://www.instagram.com/difficult_knights"); } private void btnAnalytics_Click(object sender, EventArgs e) { pnlNav.Height = btnAnalytics.Height; pnlNav.Top = btnAnalytics.Top; btnAnalytics.BackColor = Color.FromArgb(46, 51, 73); System.Diagnostics.Process.Start("https://Difficult-Knights.de"); } private void btnCalender_Click(object sender, EventArgs e) { pnlNav.Height = btnCalender.Height; pnlNav.Top = btnCalender.Top; btnCalender.BackColor = Color.FromArgb(46, 51, 73); this.pnlFormLoader.Controls.Clear(); frmCalender frmCalender_vrb = new frmCalender() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmCalender_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmCalender_vrb); frmCalender_vrb.Show(); lbltitle.Text = "Server Status"; } private void btnContactUs_Click(object sender, EventArgs e) { pnlNav.Height = btnContactUs.Height; pnlNav.Top = btnContactUs.Top; btnContactUs.BackColor = Color.FromArgb(46, 51, 73); System.Diagnostics.Process.Start("https://mobile.twitter.com/dif_knights"); } private void btnsettings_Click(object sender, EventArgs e) { pnlNav.Height = btnsettings.Height; pnlNav.Top = btnsettings.Top; btnsettings.BackColor = Color.FromArgb(46, 51, 73); this.pnlFormLoader.Controls.Clear(); frmSettings frmSettings_vrb = new frmSettings() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmSettings_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmSettings_vrb); frmSettings_vrb.Show(); lbltitle.Text = "Information"; } private void btnDashbord_Leave(object sender, EventArgs e) { btnDashbord.BackColor = Color.FromArgb(24, 30, 54); } private void btnAnalytics_Leave(object sender, EventArgs e) { btnAnalytics.BackColor = Color.FromArgb(24, 30, 54); } private void btnCalender_Leave(object sender, EventArgs e) { btnCalender.BackColor = Color.FromArgb(24, 30, 54); } private void btnContactUs_Leave(object sender, EventArgs e) { btnContactUs.BackColor = Color.FromArgb(24, 30, 54); } private void btnsettings_Leave(object sender, EventArgs e) { btnsettings.BackColor = Color.FromArgb(24, 30, 54); } private void button1_Click_1(object sender, EventArgs e) { btnsettings.BackColor = Color.FromArgb(24, 30, 54); Application.Exit(); } private void panel3_Paint(object sender, PaintEventArgs e) { } private void textBox1_Leave(object sender, EventArgs e) { } private void lbltitle_Click(object sender, EventArgs e) { } private void label1_Click(object sender, EventArgs e) { } private void label1_Click_1(object sender, EventArgs e) { } private void panel1_Paint(object sender, PaintEventArgs e) { } private void button2_Click(object sender, EventArgs e) { pnlNav.Height = btnAnalytics.Height; pnlNav.Top = btnAnalytics.Top; btnAnalytics.BackColor = Color.FromArgb(46, 51, 73); lbltitle.Text = "YouTube - Twitch Kanal"; this.pnlFormLoader.Controls.Clear(); frmAnalytics frmAnalytics_vrb = new frmAnalytics() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmAnalytics_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmAnalytics_vrb); frmAnalytics_vrb.Show(); } private void timer1_Tick(object sender, EventArgs e) { } private void pictureBox2_Click(object sender, EventArgs e) { } private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e) { } private void textBox1_TextChanged(object sender, EventArgs e) { } private void domainUpDown1_SelectedItemChanged(object sender, EventArgs e) { } private void label1_Click_2(object sender, EventArgs e) { } private void timer1_Tick_1(object sender, EventArgs e) { label1.Text = DateTime.Now.ToLongTimeString(); timer1.Start(); } private void button3_Click(object sender, EventArgs e) { System.Diagnostics.Process.Start("https://discord.com/invite/3f9Bu7pjhM"); } private void button4_Click(object sender, EventArgs e) { pnlNav.Height = btnAnalytics.Height; pnlNav.Top = btnAnalytics.Top; btnAnalytics.BackColor = Color.FromArgb(46, 51, 73); lbltitle.Text = "YouTube - Twitch Kanal"; this.pnlFormLoader.Controls.Clear(); frmAnalytics frmAnalytics_vrb = new frmAnalytics() { Dock = DockStyle.Fill, TopLevel = false, TopMost = true }; frmAnalytics_vrb.FormBorderStyle = FormBorderStyle.None; this.pnlFormLoader.Controls.Add(frmAnalytics_vrb); frmAnalytics_vrb.Show(); } private void label2_Click(object sender, EventArgs e) { } private void button5_Click(object sender, EventArgs e) { btnsettings.BackColor = Color.FromArgb(24, 30, 54); this.WindowState = FormWindowState.Minimized; } private void Form1_MouseDown(object sender, MouseEventArgs e) { dragging = true; startPoint = new Point(e.X, e.Y); } private void Form1_MouseUp(object sender, MouseEventArgs e) { dragging = false; } private void Form1_MouseMove(object sender, MouseEventArgs e) { if (dragging) { Point p = PointToScreen(e.Location); Location = new Point(p.X - this.startPoint.X, p.Y - this.startPoint.Y); } } private void frmSettings_Load(object sender, EventArgs e) { } } }