public void HandleAdditionalScreens(int mode)
{
Screen[] s = Screen.AllScreens;
for (int i = 0; i < Screen.AllScreens.Length; i++)
{
if (f[i] != null)
{
f[i].Visible = false;
}
if (!((this.Left >= s[i].Bounds.X & this.Left < (s[i].Bounds.X + s[i].Bounds.Width))) | !((this.Top >= s[i].Bounds.Y & this.Top < (s[i].Bounds.Y + s[i].Bounds.Height))))
{
if (f[i] == null)
{
f[i] = new Form();
f[i].FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
f[i].BackColor = Properties.Settings.Default.BackgroundColor;
f[i].Show();
f[i].Bounds = s[i].Bounds;
f[i].WindowState = FormWindowState.Maximized;
f[i].Opacity = Properties.Settings.Default.Opacity / 100.0;
}
else
{
if (mode == 1)
{
f[i].BackColor = Properties.Settings.Default.BackgroundColor;
f[i].Visible = true;
f[i].Opacity = Properties.Settings.Default.Opacity / 100.0;
}
else
{
f[i].Visible = false;
}
}
}
}
}