-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathForm2.cs
167 lines (148 loc) · 5.44 KB
/
Form2.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using MetroSet_UI.Controls;
using System.Drawing.Text;
using System.IO;
using System.Reflection;
namespace Netro
{
public partial class Form2 : MetroSet_UI.Forms.MetroSetForm
{
PrivateFontCollection pfc = new PrivateFontCollection();
public Form2()
{
InitializeComponent();
this.DropShadowEffect = false;
this.StyleManager = styleManager1;
linkLabel1.LinkBehavior = LinkBehavior.NeverUnderline;
linkLabel2.LinkBehavior = LinkBehavior.NeverUnderline;
this.FormBorderStyle = FormBorderStyle.None;
this.Text = "";
this.BackColor = Color.FromArgb(30, 30, 30);
this.Padding = new Padding(2);
this.StartPosition = FormStartPosition.CenterScreen;
//--------------------------------------------------------
Panel ustPanel = new Panel
{
Dock = DockStyle.Top,
Height = 40,
BackColor = Color.FromArgb(30, 30, 30)
};
this.Controls.Add(ustPanel);
Label baslik = new Label
{
Text = "About",
ForeColor = Color.White,
Font = new Font("Arial", 12, FontStyle.Bold),
AutoSize = true,
Location = new Point(135, 10),
TextAlign = ContentAlignment.TopCenter,
};
ustPanel.Controls.Add(baslik);
Button kapatma = new Button
{
Text = "✕",
ForeColor = Color.White,
BackColor = Color.FromArgb(220, 53, 69),
FlatStyle = FlatStyle.Flat,
Size = new Size(40, 30),
Location = new Point(this.Width - 50, 5),
Anchor = AnchorStyles.Top | AnchorStyles.Right
};
//--------------------------------------------------------
kapatma.FlatAppearance.BorderSize = 0;
kapatma.Click += (s, args) => this.Close();
ustPanel.Controls.Add(kapatma);
ustPanel.MouseDown += TopPanel_MouseDown;
ustPanel.MouseMove += TopPanel_MouseMove;
this.Resize += (s, args) =>
{
kapatma.Location = new Point(this.Width - kapatma.Width - 10, 5);
};
}
private Point mouseDownLocation;
private void TopPanel_MouseDown(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Left)
mouseDownLocation = e.Location;
}
private void TopPanel_MouseMove(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Left)
{
this.Left += e.X - mouseDownLocation.X;
this.Top += e.Y - mouseDownLocation.Y;
}
}
protected override void WndProc(ref Message m)
{
const int WM_NCLBUTTONDBLCLK = 0x00A3;
const int WM_LBUTTONDBLCLK = 0x0203;
if (m.Msg == WM_NCLBUTTONDBLCLK || m.Msg == WM_LBUTTONDBLCLK)
return;
base.WndProc(ref m);
}
private void Form2_Load(object sender, EventArgs e)
{
this.DropShadowEffect = false;
}
#pragma warning disable IDE1006
private void label2_Click(object sender, EventArgs e)
#pragma warning restore IDE1006
{
}
#pragma warning disable IDE1006
private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
#pragma warning restore IDE1006
{
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo
{
FileName = "https://spyhackerz.org",
UseShellExecute = true
});
}
#pragma warning disable IDE1006
private void linkLabel2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
#pragma warning restore IDE1006
{
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo
{
FileName = "https://imhateam.org/",
UseShellExecute = true
});
}
#pragma warning disable IDE1006
private void linklabel1_MouseEnter(object sender, EventArgs e)
#pragma warning disable IDE1006
{
label3.Font = new Font(label3.Font, FontStyle.Underline);
}
#pragma warning disable IDE1006
private void linklabel2_MouseLeave(object sender, EventArgs e)
#pragma warning disable IDE1006
{
label3.Font = new Font(label3.Font, FontStyle.Regular);
}
#pragma warning disable IDE1006
private void label6_Click(object sender, EventArgs e)
#pragma warning restore IDE1006
{
}
private void label3_Click(object sender, EventArgs e)
{
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo
{
FileName = "https://t.me/radoxin",
UseShellExecute = true
});
}
}
}