File size: 1,105 Bytes
e26fba6 |
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 |
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
namespace BlueTube.Viewer
{
public class TransparentPanel : Panel
{
public TransparentPanel()
{
}
/// <summary>
/// Gets the creation parameters.
/// </summary>
protected override CreateParams CreateParams
{
get
{
CreateParams createparams = base.CreateParams;
createparams.ExStyle |= 0x00000020; // WS_EX_TRANSPARENT
return createparams;
}
}
/// <summary>
/// Skips painting the background.
/// </summary>
/// <param name="e">E.</param>
protected override void OnPaintBackground(PaintEventArgs e)
{
//do nothing
//.OnPaintBackground(e);
}
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
{
return base.ProcessCmdKey(ref msg, keyData);
}
}
}
|