home *** CD-ROM | disk | FTP | other *** search
- VERSION 2.00
- Begin Form wndToolBar
- BackColor = &H00C0C0C0&
- Caption = "Toolbar"
- ClientHeight = 2040
- ClientLeft = 570
- ClientTop = 1770
- ClientWidth = 4215
- ControlBox = 0 'False
- FontBold = 0 'False
- FontItalic = 0 'False
- FontName = "MS Serif"
- FontSize = 6
- FontStrikethru = 0 'False
- FontUnderline = 0 'False
- Height = 2445
- Left = 510
- LinkTopic = "Form1"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 136
- ScaleMode = 3 'Pixel
- ScaleWidth = 281
- Top = 1425
- Width = 4335
- Begin PictureBox Toolbar
- AutoRedraw = -1 'True
- BackColor = &H00C0C0C0&
- BorderStyle = 0 'None
- ClipControls = 0 'False
- Height = 855
- Left = 0
- ScaleHeight = 855
- ScaleWidth = 4215
- TabIndex = 0
- Top = 135
- Width = 4215
- End
- Option Explicit
- Dim StartExit As Integer
- Dim StartInit As Integer
- Dim Titel As String
- Sub Form_Activate ()
- StartInit = False
- SizeControl Toolbar
- If Me.WindowState <> 0 Then Beep: Me.WindowState = 0
- vbQHCalcToolPos Toolbar
- Toolbar.Refresh
- If Me.WindowState <> 0 Then Me.WindowState = 0
- ChangeBar = False
- End Sub
- Sub Form_DblClick ()
- StartExit = -StartExit
- End Sub
- Sub Form_Load ()
- Dim h As Integer
- Dim col As Long
- StartInit = True
- Titel = Me.Caption
- Me.Tag = Titel
- Me.Caption = Chr$(0)
- Me.AutoRedraw = True
- Me.Move GetSystemMetrics(0) * Screen.TwipsPerPixelX, GetSystemMetrics(1) * Screen.TwipsPerPixelY
- Me.AutoRedraw = False
- Me.Refresh
- SetChild Me.hWnd, MDIParent.hWnd, True
- End Sub
- Sub Form_MouseDown (Button As Integer, Shift As Integer, X As Single, Y As Single)
- Dim dc As Integer
- Dim dx As Integer, dy As Integer
- Dim mPos As apiPoint
- Dim oldpos As apiPoint
- Dim mRect As apiRect
- StartExit = False
- If Y < 9 Then
- If X > 10 Then
- vbQHFakeMove Me
- Else
- Me.DrawMode = 6
- If Me.BorderStyle Then
- Me.Line (0, 0)-(10, 7), 0, BF
- Else
- Me.Line (1, 1)-(10, 7), 0, BF
- End If
- StartExit = True
- Me.DrawMode = 13
- End If
- End If
- End Sub
- Sub Form_MouseUp (Button As Integer, Shift As Integer, X As Single, Y As Single)
- Me.DrawMode = 13
- Me.Cls
- If StartExit = 1 Then Unload Me
- End Sub
- Sub Form_Paint ()
- Dim w As Integer, h As Integer
- Dim col As Long
- Static IsPainting As Integer
- If StartInit Then Exit Sub
- If IsPainting Then Exit Sub
- IsPainting = True
- w = Me.ScaleWidth
- Me.AutoRedraw = True
- If Me.BorderStyle Then
- h = 0
- Else
- h = 1
- End If
- Me.Line (0, 0)-(10, 10), RGB(192, 192, 192), BF
- col = GetSysColor(2)
- Me.Line (12, h)-(w - 1, 7), col, BF ' Titelleiste
- Me.Line (h, 8)-(w, 8), 0 ' Linie unter Titel
- Me.Line (11, h)-(11, 8), 0 ' Linie links von Titel
- Me.ForeColor = GetSysColor(9)
- Me.CurrentX = 11 + (Me.ScaleWidth - 12 - Me.TextWidth(Titel)) / 2
- Me.CurrentY = -1
- If Me.CurrentX > 11 Then Me.Print Titel
- Me.Line (3, 2 + h)-(8, 4 + h), 0, B ' Schwarzes Rechteck
- Me.Line (4, 3 + h)-(8, 3 + h), RGB(255, 255, 255)' Weiss f
- Me.Line (4, 5 + h)-(9, 5 + h), RGB(128, 128, 128)' Schatten unten
- Me.Line (9, 3 + h)-(9, 6 + h), RGB(128, 128, 128)' Schatten rechts
- Me.AutoRedraw = False
- Me.Refresh
- IsPainting = False
- End Sub
- Sub Form_Resize ()
- If Not StartInit Then
- SizeControl Toolbar
- If Me.WindowState <> 0 Then Me.WindowState = 0
- vbQHCalcToolPos Toolbar
- Me.Refresh
- End If
- End Sub
- Sub Form_Unload (Cancel As Integer)
- vbQHExit Me
- End Sub
- Sub Toolbar_MouseMove (Button As Integer, Shift As Integer, X As Single, Y As Single)
- vbQHelpExt Toolbar
- End Sub
-