forked from yaunqiying/EasyCharts
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathForm_GetColors.cs
36 lines (31 loc) · 1.06 KB
/
Form_GetColors.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
using System;
using System.Windows.Forms;
namespace ExcelAddIn_Graphics
{
public partial class Form_GetColors : Form
{
public Form_GetColors()
{
InitializeComponent();
}
private void Form_GetColors_Load(object sender, EventArgs e)
{
MaximizedBounds = Screen.PrimaryScreen.Bounds;
WindowState = FormWindowState.Maximized;
FormBorderStyle = FormBorderStyle.None;
Opacity = 0.01;
}
private void Form_GetColors_Click(object sender, EventArgs e)
{
Close();
}
private void Form_GetColors_MouseMove(object sender, MouseEventArgs e)
{
Form_ColorPixel Mymainform = (Form_ColorPixel)Tag;
if (e.X > Mymainform.Left && e.X < Mymainform.Left + Mymainform.Width && e.Y > Mymainform.Top && e.Y < Mymainform.Top + Mymainform.Width)
{
Mymainform.Location = Mymainform.Location == Mymainform.formLeft ? Mymainform.formRight : Mymainform.formLeft;
}
}
}
}