亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? modmenusxp.bas

?? 很好一套庫存管理
?? BAS
?? 第 1 頁 / 共 5 頁
字號:
        Set VisibleMenus = New Collection
    Case WM_MDIACTIVATE
        'Debug.Print "MDI child created"
        ' MDI children get their menus subclassed to the parent by Windows
        ' We set the class's parentform value to the MDI's parent & when
        ' submenus are processed, they are redirected to the parent
        ' The ChildStatus is set to clean out the parent's class when the
        ' child window is closed
        ' The GetSetMDIchildSysMenu command is run to store the system menu
        ' with the parent form. When the child is maximized its system menu
        ' shows up on the parent form & needs to be compared so the class
        ' doesn't draw for the system menu which it can't do!
        MenuData(ActiveHwnd).ParentForm = GetParent(GetParent(hwnd))
        MenuData(CStr(MenuData(ActiveHwnd).ParentForm)).GetSetMDIchildSysMenu GetSystemMenu(hwnd, False), True
        MenuData(ActiveHwnd).ChildStatus = 1
    Case WM_MEASUREITEM
        'Debug.Print "measuring"
        ' occurs after menu initialized & before drawing takes place
        ' send to drawing routine to measure the height/width of the menu panel
        ' If we measured it, don't let windows measure it again
        If CustomDrawMenu(wMsg, lParam, wParam) = True Then Exit Function
    Case WM_INITMENUPOPUP   ', WM_INITMENU
        If wParam = 0 Then Err.Raise 5  ' ignore these messages & pass them thru
        'Debug.Print "Popup starts"
        ' Occurs each time a menu is about to be displayed, wMsg is the handle
        ' Send flag to drawing routine to allow icons to be redrawn
        CustomDrawMenu wMsg, 0, 0
        GetMenuMetrics wParam    ' get measurements for menu items
        ' allow message to pass to the destintation
    Case WM_DRAWITEM
        'Debug.Print "drawing"
        ' sent numerous times, just about every time the mouse moves
        ' over the menu. Send flag to redraw menu if needed
        ' If we drew it, don't let windows redraw it
        If CustomDrawMenu(wMsg, lParam, wParam) = True Then Exit Function
    Case WM_EXITMENULOOP
        'Debug.Print "exiting loop"
        ' When a menu is clicked on or closed, we remove the collection of submenus
        ' so they can be redrawn again as needed
        Set VisibleMenus = Nothing
    Case WM_ENTERIDLE
        'Debug.Print "Popup ends"
        ' occurs after the entire menu has been measured & displayed
        ' at least once. Send flag to not redraw icons
        CustomDrawMenu wMsg, 0, 0
End Select
SendMessageAsIs:
MsgProc = CallWindowProc(MenuData(ActiveHwnd).OldWinProc, hwnd, wMsg, wParam, lParam)
End Function

Public Function GetMenuIconID(Menu_Caption As String) As Long
' =====================================================================
'   Returns the icon assigned in the menu caption as a long value
'   Example: {IMG:9}&Open would return 9
'   Note: Not used in any modules here, but provided for programmer use
'         if needed in their applications
' =====================================================================
Dim i As Integer
On Error GoTo NoIcon
i = InStr(Menu_Caption, "{IMG:")
If i Then
    GetMenuIconID = VAL(Mid$(Menu_Caption, InStr(Menu_Caption, ":") + 1))
End If
Exit Function
NoIcon:
GetMenuIconID = 0
End Function

Private Sub GetMenuMetrics(hSubMenu As Long)
' =====================================================================
' Routine gets the meaurements of the submenus & their submenus,
'   their checked status, enabled status,
'   control keys, icon index, etc
' =====================================================================

Dim lMenus As Long, hWndRedirect As String
Dim Looper As Long, meDC As Long, lmnuID As Long, sysMenuLoc As Long
Dim mII As MENUITEMINFO, mI() As Byte
Dim tRect As RECT, lMetrics(0 To 10) As Long
Dim sCaption As String, sBarCaption As String
Dim sHotKey As String, bTabOffset As Boolean
Dim IconID As Integer, iTransparency As Integer
Dim bSetHotKeyOffset As Boolean, bNewItem As Boolean
Dim bHasIcon As Boolean, bRecalcSideBar As Long
Dim iSeparator As Integer, bSpecialSeparator As Boolean

On Error Resume Next
If MenuData(ActiveHwnd).GetSetMDIchildSysMenu(hSubMenu, False) = True Then Exit Sub
If Not VisibleMenus Is Nothing Then
    ' here we track which submenus are currently visible so we don't
    ' re-process data which isn't needed until after the submenu is closed
    lMenus = VisibleMenus(CStr(hSubMenu))
    If lMenus Then Exit Sub
End If
On Error GoTo 0
meDC = GetDC(CLng(ActiveHwnd))
hWndRedirect = MenuData(ActiveHwnd).ParentForm
' Get the ID for the next submenu item
lMenus = GetMenuItemCount(hSubMenu)
lSubMenu = hSubMenu
modDrawing.TargethDC = meDC
DetermineOS
With MenuData(hWndRedirect)         ' class for this form
    For Looper = 0 To lMenus - 1    ' loop thru each subitem
        ' get the submenu item
        bSpecialSeparator = False
        iSeparator = 0: iTransparency = 0
        sHotKey = ""
        ' now set some flags & stuff to return the caption,  checked & enabled status
        ' by referencing the dwTypeData as a byte array vs long or string,
        ' we bypass the VB crash that happens on Win98 & XP & probably others
        ReDim mI(0 To 255)
        mII.cbSize = Len(mII)
        mII.fMask = &H10 Or &H1 Or &H2
        mII.fType = 0
        mII.dwTypeData = VarPtr(mI(0))
        mII.cch = UBound(mI)
        ' get the submenu item information
        GetMenuItemInfo hSubMenu, Looper, True, mII
        'Debug.Print lmnuID; "has submenus"; mII.hSubMenu
        If Abs(mII.wID) = 4096 Or mII.wID = -1 Then Exit Sub
        lmnuID = mII.wID
        bNewItem = .SetMenuID(lmnuID, hSubMenu, False, True)
        sCaption = Left$(StrConv(mI, vbUnicode), mII.cch)
        If Len(Replace$(sCaption, Chr$(0), "")) = 0 Then sCaption = .OriginalCaption
        If Left(UCase(sCaption), 9) = "{SIDEBAR:" Then sBarCaption = sCaption
        'Debug.Print hWndRedirect; hSubMenu; lmnuID; " Caption: "; sCaption
        If .OriginalCaption = sCaption And bNewItem = False Then
            ' here we can get cached info vs reprocessing it again
            lMetrics(1) = lMetrics(1) + .ItemHeight
            lMetrics(10) = .ItemWidth
            If LoWord(lMetrics(10)) > lMetrics(0) Then lMetrics(0) = LoWord(lMetrics(10))
            If HiWord(lMetrics(10)) > lMetrics(9) Then lMetrics(9) = HiWord(lMetrics(10))
            lMetrics(4) = .SideBarWidth
            If .Icon <> 0 Then bHasIcon = True
            If InStr(sCaption, Chr$(9)) Then bTabOffset = True
            'Debug.Print "reading existing " & Looper + 1, sCaption
        Else
            bNewItem = True
            If Len(sBarCaption) > 0 And bRecalcSideBar = 0 Then bRecalcSideBar = lmnuID
            .OriginalCaption = sCaption
            .Status = 0
            ' new item or change in caption, let's get some measurements
            ' first extract the caption, controlkeys & icon
            If InStr(sCaption, Chr$(9)) Then bTabOffset = True
            ' when Win98 encounters a hotkey above, it automatically
            ' increases the menu panel width. We need to note that
            ' so we can decrease the panel widh appropriately and
            ' offset the automatic increase. This helps prevent extra
            ' wide menu panels
            If Left(UCase(sCaption), 9) = "{SIDEBAR:" Then
                iSeparator = 1
                .Status = .Status Or 16
                .ItemHeight = 0
                .ItemWidth = 0
                .Icon = 0
            Else
                'Debug.Print "Caption "; sCaption
                FindImageAndHotKey hWndRedirect, sCaption, iTransparency, sHotKey, IconID
                Debug.Print "iconid="; IconID
                ' identify whether or not this is a separator
                iSeparator = Abs(CInt(Len(sCaption) = 0 Or Left$(sCaption, 1) = "-"))
                If iSeparator = 0 Then iSeparator = Abs(CInt(mII.fType And MF_SEPARATOR) = MF_SEPARATOR)
                If iSeparator Then IconID = 0   ' no pictures on separator bars!
                If Len(sCaption) > 0 And iSeparator = 1 Then
                    ' separator bar with text
                    ' calculate entire caption & set a few flags
                    sCaption = Mid$(sCaption, 2) & "  " & sHotKey
                    bSpecialSeparator = True
                    sHotKey = ""                ' not used for separators
                End If
                ' start saving the information
                .Caption = Trim$(sCaption & " " & sHotKey)
                .Icon = IconID
                .Status = .Status Or iTransparency * 4
                .Status = .Status Or iSeparator * 2
                If IconID Then bHasIcon = True
                SetMenuFont True, , bSpecialSeparator    ' add smaller menu font
                ' measure the caption width to help identify how wide
                ' the menu panel should be (greatest width of all submenu items)
                DrawText meDC, sCaption, Len(sCaption), tRect, DT_CALCRECT Or DT_LEFT Or DT_SINGLELINE Or DT_NOCLIP
                ' keep track of the largest width, this will be used to
                ' left align control keys for the entire panel
                If tRect.Right > lMetrics(0) Then lMetrics(0) = tRect.Right
                lMetrics(10) = tRect.Right
                If iSeparator = 0 Or bSpecialSeparator = True Then
                    ' set min height text menu items to match 16x16 icon height
                    If tRect.Bottom < 10 And bSpecialSeparator = False Then tRect.Bottom = 10
                    tRect.Bottom = tRect.Bottom + 6
                Else
                    tRect.Bottom = 5    ' make default separators 0 height
                End If
                ' store the height of the caption text
                .ItemHeight = tRect.Bottom
                lMetrics(1) = lMetrics(1) + tRect.Bottom
                SetMenuFont False
                If Len(sHotKey) Then
                    .HotKeyPos = Len(sCaption) + 1
                    ' now do the same for the hotkey
                    DrawText meDC, Trim(sHotKey), Len(Trim(sHotKey)), tRect, DT_CALCRECT Or DT_LEFT Or DT_NOCLIP Or DT_SINGLELINE
                    ' keep track of the widest control key text
                    ' this is used w/widest caption to determine overall
                    ' panel width including icons & checkmarks. Add 12 pixels for
                    ' buffer between end of caption & beginning of control key
                    If tRect.Right > lMetrics(9) Then lMetrics(9) = tRect.Right
                    .ItemWidth = MakeLong(CInt(lMetrics(10)), CInt(tRect.Right))
                Else
                    .ItemWidth = MakeLong(CInt(lMetrics(10)), 0)
                End If
            End If
        End If
        ' we ensure the item is drawn by us
        ' force a separator status if appropriate
        mII.fMask = 0
        If mII.fType = MF_SEPARATOR Or iSeparator = 1 Then
           mII.fType = MF_SEPARATOR Or MF_OWNERDRAW
        Else    ' otherwise it's normal
           mII.fType = mII.fType Or MF_OWNERDRAW
        End If
        mII.fMask = mII.fMask Or MIIM_TYPE Or MIIM_DATA   ' reset mask
        ' save updates to allow us to draw the menu item
        SetMenuItemInfo hSubMenu, Looper, True, mII
    Next
    If Looper > 0 Then  ' menu items processed
        If bRecalcSideBar = 0 Then  ' sidebar menu id
            ' if no sidebar was processed, then check the overall panel height
            ' if it changed, we need to reprocess the sidebar again since
            ' the graphics & text are centered in the panel
            If .PanelHeight <> lMetrics(1) And .SideBarItem <> 0 Then bRecalcSideBar = lmnuID
        End If
        lMetrics(3) = 5 + Abs(CInt(bHasIcon)) * 18
        lMetrics(2) = lMetrics(0) + 12
        lMetrics(0) = lMetrics(2) + lMetrics(9) + lMetrics(3) + lMetrics(4) + CInt(bTabOffset) * iTabOffset
        If bRecalcSideBar Then
            .SetMenuID bRecalcSideBar, hSubMenu, False, False
            ReturnSideBarInfo hWndRedirect, sBarCaption, lMetrics(), meDC
        End If
        .UpdatePanelID lMetrics(), sBarCaption, (bRecalcSideBar = 0)
    End If
End With
If Not VisibleMenus Is Nothing Then VisibleMenus.Add 1, (CStr(hSubMenu))
' now we replace the default font & release the form's DC
SetMenuFont False, meDC
ReleaseDC CLng(ActiveHwnd), meDC
Erase lMetrics
Erase mI
End Sub

Private Sub FindImageAndHotKey(hWndRedirect As String, sKey As String, imgTransparency As Integer, sAccel As String, imgIndex As Integer)
' =====================================================================
' This routine extracts the imagelist refrence and resets it if the
' image doesn't exist or not imagelist was provided
' =====================================================================
On Error Resume Next
Dim i As Integer, sSpecial As String, sHeader As String
imgIndex = 0
imgTransparency = 0
If Left$(UCase(sKey), 5) = "{IMG:" Then
    i = InStr(sKey, "}")
    If i Then
        sHeader = UCase(Left$(sKey, i))
        sKey = Mid$(sKey, i + 1)
        ' extract the image index
        imgIndex = VAL(Mid$(sHeader, 6))
        ' if the value<1 or >nr of images, then reset it to zero
        Debug.Print "icon count="; MenuData(hWndRedirect).TotalIcons

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲制服丝袜在线| 国产女人18水真多18精品一级做| 国产91色综合久久免费分享| 蜜臀av亚洲一区中文字幕| 亚洲精品国产无套在线观| 国产精品视频观看| 国产欧美日韩综合精品一区二区 | 亚洲图片自拍偷拍| 一区二区三区久久久| 亚洲主播在线观看| 午夜成人在线视频| 免费欧美高清视频| 久久99国产精品免费| 久久99蜜桃精品| 国产激情偷乱视频一区二区三区| 国产在线视视频有精品| 国产成人精品一区二| 国产91精品免费| 91美女片黄在线观看| 在线观看av一区二区| 欧美精品久久一区| 9191成人精品久久| 久久影院午夜片一区| ...av二区三区久久精品| 亚洲精品videosex极品| 日韩电影在线观看一区| 国产一区二区女| 99天天综合性| 欧美精品成人一区二区三区四区| 日韩精品资源二区在线| 亚洲国产精品黑人久久久| 亚洲人精品午夜| 久久成人av少妇免费| 99在线精品免费| 精品人伦一区二区色婷婷| 成人欧美一区二区三区白人| 免费一级片91| 色琪琪一区二区三区亚洲区| 欧美一区中文字幕| 国产精品久久久一本精品| 午夜精品福利在线| 成人的网站免费观看| 欧美久久久久久久久中文字幕| 久久精品综合网| 午夜精品久久久久久| 成人ar影院免费观看视频| 制服丝袜亚洲色图| 综合欧美亚洲日本| 国内精品写真在线观看| 欧美色视频在线| 国产精品美女一区二区三区| 喷白浆一区二区| 欧美这里有精品| 欧美国产精品一区二区三区| 免费人成精品欧美精品| 欧洲色大大久久| 国产精品夫妻自拍| 精品一区二区三区视频在线观看 | 欧美日韩久久久久久| 国产婷婷色一区二区三区| 午夜精品久久一牛影视| 色婷婷狠狠综合| 日韩理论片网站| 国产69精品久久久久毛片| 欧美一级高清大全免费观看| 亚洲国产精品久久久男人的天堂 | 亚洲精品v日韩精品| 国产成人小视频| 26uuu亚洲综合色欧美| 污片在线观看一区二区| 欧美午夜电影在线播放| 亚洲欧美偷拍另类a∨色屁股| 国产精品一区二区免费不卡| 欧美电视剧免费观看| 免费av成人在线| 日韩免费在线观看| 热久久久久久久| 日韩欧美aaaaaa| 日本伊人午夜精品| 日韩一级黄色大片| 久久99国产精品麻豆| 欧美大片一区二区| 国产在线播放一区三区四| www成人在线观看| 激情综合色综合久久综合| 欧美精品一区二区三区蜜桃视频| 免费在线成人网| 久久综合色鬼综合色| 国产成人在线色| 国产精品九色蝌蚪自拍| 一本久道中文字幕精品亚洲嫩| 亚洲视频精选在线| 欧美亚洲国产一区二区三区va| 亚洲电影视频在线| 欧美一区午夜视频在线观看| 国产一区二区女| 国产精品国产三级国产aⅴ中文 | 一区二区三区成人| 欧美丝袜丝nylons| 精品一区二区影视| 成人欧美一区二区三区视频网页| 欧美伊人久久大香线蕉综合69 | 国产成人免费在线观看| 国产精品高潮呻吟久久| 欧美三级韩国三级日本一级| 美腿丝袜在线亚洲一区| 国产欧美日韩精品在线| 欧美在线观看一区二区| 久久爱www久久做| 成人免费在线播放视频| 在线电影国产精品| 成人99免费视频| 日韩精品成人一区二区在线| 国产日产亚洲精品系列| 91黄视频在线| 国产乱人伦精品一区二区在线观看| 亚洲欧洲精品一区二区三区不卡| 欧美久久久久久久久久| 成人黄色免费短视频| 日韩激情av在线| 国产精品第13页| 精品国产成人系列| 欧美日韩精品高清| 97精品视频在线观看自产线路二| 午夜精品爽啪视频| √…a在线天堂一区| 欧美sm极限捆绑bd| 欧美丝袜自拍制服另类| av一本久道久久综合久久鬼色| 日本在线不卡视频| 亚洲国产精品久久久久秋霞影院 | 亚洲一区二区三区爽爽爽爽爽| 久久一区二区视频| 3atv一区二区三区| 在线观看日韩电影| 92国产精品观看| 懂色一区二区三区免费观看| 青椒成人免费视频| 婷婷成人综合网| 亚洲一区二区高清| 一区二区三区日韩在线观看| 国产精品免费久久| 欧美国产成人精品| 久久久午夜精品| 久久久国际精品| 久久日韩粉嫩一区二区三区| 精品少妇一区二区三区| 91超碰这里只有精品国产| 欧美精品粉嫩高潮一区二区| 欧美日韩国产综合一区二区 | 日韩视频在线观看一区二区| 欧美无乱码久久久免费午夜一区| 91亚洲大成网污www| 91亚洲永久精品| 91国产免费观看| 91精品福利视频| 欧美日韩一级黄| 7777女厕盗摄久久久| 欧美一区二区美女| 日韩美女视频在线| 久久久影院官网| 国产日韩欧美a| 国产精品亲子伦对白| 国产精品久久久久影院色老大| 国产精品久久网站| 亚洲精品视频一区二区| 亚洲一级二级在线| 日韩二区三区四区| 国产精品99久久久| 成人av综合在线| 欧美婷婷六月丁香综合色| 91精品国产综合久久国产大片 | 久久综合视频网| 国产精品污网站| 一区二区免费在线播放| 日韩成人一级大片| 国产九色sp调教91| 91丨九色porny丨蝌蚪| 欧美三级视频在线| 久久久久久久久久久久久久久99| 久久伊人蜜桃av一区二区| 国产精品成人免费精品自在线观看| 亚洲欧美日韩电影| 午夜影院久久久| 国产精品亚洲专一区二区三区 | 国产成人午夜精品影院观看视频| 成人免费毛片高清视频| 欧美探花视频资源| www日韩大片| 亚洲最色的网站| 国产在线视频精品一区| 色噜噜狠狠一区二区三区果冻| 欧美精品第1页| 中文字幕一区二区三区精华液| 日日欢夜夜爽一区| 播五月开心婷婷综合| 91精品国产综合久久久久久漫画| 久久精品视频一区二区三区| 亚洲第一综合色| 99久久精品国产网站|