private void ShowHideWindow(bool isShow)
{
if(isShow)
{
if(this.ShowInTaskbar==false)
{
this.ShowInTaskbar = true;
this.Show();
this.WindowState = FormWindowState.Normal;
}
else
{
if(this.WindowState == FormWindowState.Minimized)
{
this.WindowState = FormWindowState.Normal;
}
}
this.Activate();
}
else
{
if(this.ShowInTaskbar == true)
{
this.Hide();
this.ShowInTaskbar = false;
}
}
}
{
if(isShow)
{
if(this.ShowInTaskbar==false)
{
this.ShowInTaskbar = true;
this.Show();
this.WindowState = FormWindowState.Normal;
}
else
{
if(this.WindowState == FormWindowState.Minimized)
{
this.WindowState = FormWindowState.Normal;
}
}
this.Activate();
}
else
{
if(this.ShowInTaskbar == true)
{
this.Hide();
this.ShowInTaskbar = false;
}
}
}