VERSION 5.00
Begin VB.UserControl UserControl1 
   BackStyle       =   0  'Transparent
   ClientHeight    =   3600
   ClientLeft      =   0
   ClientTop       =   0
   ClientWidth     =   4800
   ScaleHeight     =   3600
   ScaleWidth      =   4800
   Begin VB.PictureBox picMask 
      AutoRedraw      =   -1  'True
      BackColor       =   &H00FFFF00&
      BorderStyle     =   0  'None
      FillColor       =   &H000000FF&
      FillStyle       =   0  'Solid
      Height          =   840
      Left            =   2760
      ScaleHeight     =   840
      ScaleWidth      =   1575
      TabIndex        =   1
      Top             =   1335
      Width           =   1575
      Visible         =   0   'False
   End
   Begin VB.PictureBox picShape 
      AutoRedraw      =   -1  'True
      BackColor       =   &H00FFFFFF&
      BorderStyle     =   0  'None
      FillColor       =   &H000000FF&
      FillStyle       =   0  'Solid
      Height          =   480
      Left            =   2730
      ScaleHeight     =   480
      ScaleWidth      =   1125
      TabIndex        =   0
      Top             =   360
      Width           =   1125
      Visible         =   0   'False
   End
End
Attribute VB_Name = "UserControl1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = False
Option Explicit

Public Event MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
Public Event MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Public Event MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
Public Event Click()

Private Sub picShape_Click()
    RaiseEvent Click
End Sub

Private Sub UserControl_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    RaiseEvent MouseDown(Button, Shift, X, Y)
End Sub

Private Sub UserControl_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    RaiseEvent MouseMove(Button, Shift, X, Y)
End Sub

Private Sub UserControl_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
    RaiseEvent MouseUp(Button, Shift, X, Y)
End Sub

Private Sub UserControl_Resize()
    picShape.Cls
    picMask.Cls
    MaskColor = picMask.BackColor
    picShape.Move 0, 0, ScaleWidth, ScaleHeight
    picMask.Move 0, 0, ScaleWidth, ScaleHeight
    picShape.Circle (ScaleWidth \ 2, ScaleHeight \ 2), ScaleWidth \ 2, , , , ScaleHeight / ScaleWidth
    picMask.Circle (ScaleWidth \ 2, ScaleHeight \ 2), ScaleWidth \ 2, , , , ScaleHeight / ScaleWidth
    Picture = picShape.Image
    MaskPicture = picMask.Image
End Sub
