Option Strict Off
Option Explicit On
'------------------------------------ 2024/04/01 ------------------------------------
Public Class frmMain

#Region "愰尵"
    '***********************************************************************
    Private mNew幚峴拞 As Boolean = True
    Public oo僐儗僐僐 As New Cls僐儗僐僐
    Public oo僗僀僗僀 As New 屲cls僗僀僗僀
    Public WithEvents oo儐儔儐儔 As New 屲cls儐儔儐儔
    Public mMenuHight As Integer
    Public mmLoading As Boolean
    Private mIniReading As Boolean = False
    Private m僒僀僘僙僢僩嬛巭 As Boolean
    Private TimEventOnStr As String = ""
    Private mCallFromFormLoad As Boolean = False
    Private mCall_In_frmMain_ResizeEnd As Boolean = False
    Private mOldWndState As FormWindowState = FormWindowState.Normal
    '***********************************************************************
    Private WithEvents 僀儀儞僩gAppEventMaker As 屲clsEventMaker
    '***********************************************************************
#End Region

#Region "AppIniFileOp"
    '仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴仴
    Friend Function aaAppIniFileOp(ByVal Load_0_QueryUnload_1_Resize_2_DoIniSave_3 As Long, ByRef rwIniDataStr() As String) As Boolean
        Return zzAppIniFileOp(Load_0_QueryUnload_1_Resize_2_DoIniSave_3, rwIniDataStr)
    End Function
    Private Function zzAppIniFileOp(ByVal Load_0_QueryUnload_1_Resize_2_DoIniSave_3 As Long, ByRef rwIniDataStr() As String) As Boolean
        '仧仧仧儊僀儞儂乕儉偵偺傒愝掕偡傞僐乕僪仧仧仧丂儊僀儞儂乕儉撪偐傜偺傒屇傃弌偟傑偡丅
        '撉弌偟帪偵丂INI 僼傽僀儖偑懚嵼偟側偄応崌偼丂False丂傪曉偟傑偡丅
        If gggAppIniFile Is Nothing Then Return False
        Try
            Dim RETVAL = False
            Dim Open0_Save1 As Long, opcode As Integer
            Open0_Save1 = Load_0_QueryUnload_1_Resize_2_DoIniSave_3
            With gggAppIniFile
                Select Case Open0_Save1
                    Case 0, 1
                        opcode = 0    'or ... 捛壛偱偒傞僐乕僪  ---> 屲clsAppINI.cAppIniCaption Or 屲clsAppINI.cAppIniBackColor Or 屲clsAppINI.cAppIniForeColor
                        RETVAL = gggAppIniFile.OpenSaveMain(Open0_Save1, Me.Name + "0012", Me, 屲clsAppINI.cAppIniFormPostSize Or opcode)  'or ... 捛壛偱偒傞僐乕僪  ---> , Text1, 屲clsAppINI.cAppIniText Or 屲clsAppINI.cAppIniTextSelSttLen Or 屲clsAppINI.cAppIniFontName Or 屲clsAppINI.cAppIniFontSize, List1, 屲clsAppINI.cAppIniList Or 屲clsAppINI.cAppIniListIndex, Check1, 屲clsAppINI.cAppIniValue,  ETC ........)
                        '******************************************************************************************************
                        gggint = gggAppIniFile.OpenSaveStrAry(Open0_Save1, Me.Name + "5522", Me, rwIniDataStr)
                        '******************************************************************************************************
                    Case 2
                        '偦傟偧傟偺僼僅乕儉偱丄埵抲偲僒僀僘偺僨乕僞乕傪曐懚偟傑偡丅
                        RETVAL = gggAppIniFile.FormSizeDataSetOnReSize(Me)
                End Select
                '******************************************************************************************************
                '儐乕僓乕傾僾儕偐傜柧帵揑偵 INI 僼傽僀儖傪曐懚偟傑偡丅
                If Open0_Save1 = 1 Then
                    gggint = gggAppIniFile.IniFileSaveDo
                End If
                '******************************************************************************************************
            End With
            Return RETVAL
        Catch
            MsgBox(ErrorToString)
        End Try
        Return False
    End Function
    ''仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯仯
#End Region

#Region "僼僅乕儉僀儀儞僩"
    '***********************************************************************
    Public Sub New()
        ' 偙偺屇傃弌偟偼丄Windows 僼僅乕儉 僨僓僀僫偱昁梫偱偡丅
        InitializeComponent()
        ' InitializeComponent() 屇傃弌偟偺屻偱弶婜壔傪捛壛偟傑偡丅
    End Sub
    '***********************************************************************
    Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
#If DEBUG Then
#Else
#End If
        '***********************************************************************
        mNew幚峴拞 = False
        '***********************************************************************
        Dim 摿暿側嵟彫尷奅僒僀僘 As Integer = (app僇乕僪孮椞堟嵟彫僒僀僘 \ 11) * 11
        If Not GMCOM傾僾儕MainForm弶婜壔_Pack(僀儀儞僩gAppEventMaker, Me, mmLoading, 摿暿側嵟彫尷奅僒僀僘, mMenuHight, MainMenu1, Nothing, Nothing, Nothing, pct儊僀儞) Then End
        '***********************************************************************
        gm傾僾儕屌桳僋儔僗 = oo僐儗僐僐
        gm僗僀僗僀嫟梡僋儔僗 = oo僗僀僗僀
        Try
            gggbol = gm傾僾儕屌桳僋儔僗.aa弶婜愝掕僆僽僕僃愝掕()
            gggbol = oo僗僀僗僀.aa弶婜愝掕()
            '***********************************************************************
            If Not GMCOM傾僾儕MainForm_AppIniFile憖嶌(Me, mIniReading) Then End
            '***********************************************************************
            gggstr = gm傾僾儕屌桳僋儔僗.aaDlgFile僎乕儉梡_aa僂僀儞僪僂弶婜壔嶌惉_After_Ini_Read()
            gggstr = oo僗僀僗僀.aaDlgFile僗僀僗僀梡_aa僂僀儞僪僂弶婜壔嶌惉_After_Ini_Read()
            '----------------------------------------
            mmLoading = False
            '----------------------------------------
            gggbol = 嘳Form_嵟彫壔忬懺側傜_昗弨僒僀僘偵栠偡(Me, m僒僀僘僙僢僩嬛巭)
            '----------------------------------------
            Me.pct儊僀儞.Cursor = New Cursor(Me.GetType(), "hand.CUR")
            gggbol = 嘳Forms_Controls_僪儔僢僌僪儘僢僾傪壜擻偵偡傞(Me, pct儊僀儞, pctBmp, Nothing, Nothing)
            '----------------------------------------
            Call aa僎乕儉僋儕傾(False)
            '----------------------------------------
            '----------------------------------------
            '2023/06/21 偙偺僐乕僪偺埵抲偱丄僗僞乕僩帪偺彫偝側丂BitMap Picturebox丂偺僄儔乕昞帵忬懺偵娭楢偡傞丅
            mCallFromFormLoad = True : Call frmMain_ResizeEnd(Nothing, Nothing) : mCallFromFormLoad = False
            '----------------------------------------
            '----------------------------------------
            gggbol = GMCOM傾僾儕MainForm弶婜壔_Pack_2222(MainMenu1, mnbbb嵟戝壔, pnl僎乕儉寢壥)
            '----------------------------------------
            Call 僀儀儞僩gAppEventMaker_僗僀僗僀偲儐儔儐儔奐巒偲掆巭()
            Call 僀儀儞僩gAppEventMaker_僗僀僗僀儐儔儐儔夋憸昞帵ONOFF(oo僗僀僗僀.p僗僀僗僀攚宨夋憸傪昞帵)
            '*************************************************************
            gggbol = 嘳Forms_嵟戝壔_昗弨壔_儊僯儏乕憖嶌(0, Me, mnbbb嵟戝壔)
            '*************************************************************
        Catch ex As Exception
            MsgBox(ErrorToString())
            gm傾僾儕廔椆偡傞 = True
        End Try
        '2023/07/15 test code
        'qqqqq(嘳僼儖僷僗柤偐傜僼傽僀儖柤偁傞偄偼嵟屻偺僼僅儖僟柤傪摼傞("..\..\", True))
        '2023/07/15 test code
        Exit Sub
    End Sub
    '***********************************************************************
    Private Sub frmMain_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
        'qqqqq("仴 frmMain_FormClosing 仴仴仴仴仴仴仴仴仴仴")
        Dim Cancel As Boolean = e.Cancel
        Dim UnloadMode As System.Windows.Forms.CloseReason = e.CloseReason

        Me.Cursor = Cursors.Default
        '----------------------------------------------
        Call aa僎乕儉僋儕傾(False)
        '----------------------------------------------
        Dim IniDataStr() As String = {""}
        Call aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒(gco僾儘僷iniWR, IniDataStr) '僾儘僷僥傿傪 INI 僼傽僀儖梡偺暥帤楍偵愝掕偡傞丅

        gm傾僾儕廔椆偡傞 = True
        '---------------------------------------------------------------------------
        gggint = zzAppIniFileOp(1, IniDataStr)  '昁偢屇傃弌偟傑偡丅
        '---------------------------------------------------------------------------
        e.Cancel = Cancel
    End Sub
    '***********************************************************************
    Private Sub frmMain_FormClosed(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosedEventArgs) Handles Me.FormClosed
        gggbol = 嘳嘳嘳AppOwnHDC_make_del_in_AppMain_Form_Load_FormClose_傕偟僄儔乕側傜_End_偡傞(2) '''''''''''', Nothing)
    End Sub
    '***********************************************************************
    Private Sub frmMain_Disposed(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Disposed
        'qqqqq("仠 frmMain_Disposed 仠仠仠仠仠仠仠仠仠仠仠仠仠仠仠仠仠仠")
    End Sub
    '***********************************************************************
    Private Sub frmMain_SizeChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.SizeChanged
        Static oldWndState As FormWindowState
        If mCall_In_frmMain_ResizeEnd Then Return
        If Me.WindowState <> oldWndState Then
            oldWndState = Me.WindowState
            If Me.WindowState <> FormWindowState.Minimized Then
                If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then
                    Call frmMain_ResizeEnd(Nothing, Nothing)
                Else
                    pct儊僀儞.Visible = False : pctBmp.Left = 10000
                    TimEventOnStr = "frmMain_SizeChanged"
                    TimEventOn.Enabled = True
                End If
            Else
                Call frmMain_ResizeEnd(Nothing, Nothing) '僼儔僌愝掕偺傒偱婣偭偰偔傞
            End If
        End If
    End Sub
    '***********************************************************************
    Private Sub frmMain_Resize(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Resize
        If mCall_In_frmMain_ResizeEnd Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟傕掆巭偟偰偄傞 Then
            pct儊僀儞.Visible = False : pctBmp.Left = 10000
        End If
    End Sub
    '***********************************************************************
    Private Sub frmMain_ResizeEnd(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.ResizeEnd
        Static mOldWD, mOldHT As Integer : Static 僐僐偐傜屇傃弌偟偨 As Boolean
        '----------------------------------------
        ''If mCall_In_frmMain_ResizeEnd Then Return  2023/03/02 偙偺僐乕僪偱偼僄儔乕偵側傞丂僐儗僐僐偺応崌偺傒丅
        If mmLoading = True Then Return
        If m僒僀僘僙僢僩嬛巭 Then Return
        If gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡 Is Nothing Then Return
        If mIniReading Then Return
        If Me.WindowState = FormWindowState.Minimized Then Return
        If 僐僐偐傜屇傃弌偟偨 Then
            僐僐偐傜屇傃弌偟偨 = False : Return
        End If
        If pct儊僀儞.Visible = True And mCallFromFormLoad = False Then 'on Me.WindowState iconic --> normal
            If mOldWD = Me.Width And mOldHT = Me.Height Then Return
        End If
        '----------------------------------------
        gggbol = 嘳FormSizeChang嵟彫僒僀僘埲忋偵_僼儔僌愝掕晅(mCall_In_frmMain_ResizeEnd, Me, mMenuHight, app僇乕僪孮椞堟嵟彫僒僀僘, app僇乕僪孮椞堟嵟彫僒僀僘, 僐僐偐傜屇傃弌偟偨)
        '----------------------------------------
        If Not mCallFromFormLoad Then
            If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then
                If mOldWD <> Me.Width Or mOldHT <> Me.Height Or mOldWndState <> Me.WindowState Then
                    pct儊僀儞.Visible = False : pctBmp.Left = 10000
                    Me.BackColor = Color.White
                    Me.Refresh()
                End If
                gm僗僀僗僀嵞僗僞乕僩尨場 = gcFormResize
            Else
                Dim YY As Integer = mMenuHight
                Dim WD As Integer = Math.Max(100, Me.ClientSize.Width)
                Dim HT As Integer = Math.Max(100, Me.ClientSize.Height - mMenuHight)
                pct儊僀儞.SetBounds(0, YY, WD, HT)
                pctBmp.SetBounds(pctBmp.Left, YY, WD, HT)
                If mmLoading Then
                    mmLoading = False
                ElseIf pp僎乕儉幚峴拞 Then
                    僐僐偐傜屇傃弌偟偨 = True
                    If (mOldWD <> Me.Width Or mOldHT <> Me.Height) And (Me.WindowState <> FormWindowState.Minimized) Then
                        gggbol = gm傾僾儕屌桳僋儔僗.aa昤夋梡_pctBoxs_僙僢僩Image(Me, "")
                    End If
                    Call gm傾僾儕屌桳僋儔僗.aa僼僅乕儉僒僀僘僙僢僩偲僇乕僪偺攝抲偲嵞昤夋(IIf(pp僎乕儉幚峴拞, 2, 3))
                    僐僐偐傜屇傃弌偟偨 = False
                ElseIf (Not pp僎乕儉幚峴拞) Then
                    gggbol = gm傾僾儕屌桳僋儔僗.aa昤夋梡_pctBoxs_僙僢僩Image(Me, "")
                End If
                gm僗僀僗僀嵞僗僞乕僩尨場 = 0
            End If
        End If
        '----------------------------------------
        pctBmp.Left = 0
        If pp僗僀僗僀僼儔僼儔_偄偢傟傕掆巭偟偰偄傞 Then
            If pp僎乕儉幚峴拞 Then pct儊僀儞.Visible = True Else pctBmp.Visible = True
            gm僗僀僗僀嵞僗僞乕僩尨場 = 0
        Else
            pct儊僀儞.Visible = False
            gm僗僀僗僀嵞僗僞乕僩尨場 = gcFormResize
        End If
        '----------------------------------------
        gggint = zzAppIniFileOp(2, gggstrary)
        '----------------------------------------
        mOldWD = Me.Width : mOldHT = Me.Height : mOldWndState = Me.WindowState
        '----------------------------------------
        'Static mmm As Integer
        'mmm = mmm + 1 : qqqqq("仭仭frmMain_ResizeEnd " + Format(mmm, "0000"))
        'qqqqq("Form OLD WD/HT  = " + CStr(mOldWD) + ", " + CStr(mOldHT))
        'qqqqq("Form new WD/HT  = " + CStr(Me.Width) + ", " + CStr(Me.Height))
        'qqqqq("仭仭frmMain_ResizeEnd")
        'qqqqq("app僇乕僪孮椞堟嵟彫僒僀僘            = " & CStr(app僇乕僪孮椞堟嵟彫僒僀僘))
        'qqqqq("Form.ClientSize.Height - mMenuHight = " & CStr(Me.ClientSize.Height - mMenuHight))
        'qqqqq("Form.ClientSize.Width               = " & CStr(Me.ClientSize.Width))
        'qqqqq("Form.Height - Form.ClientSize.Height = " & CStr(Me.Height - Me.ClientSize.Height))
        'qqqqq("Form.Height - Form.ClientSize.Height + mMenuHight = " & CStr(Me.Height - Me.ClientSize.Height + mMenuHight))
        'qqqqq("Form.Width - Form.ClientSize.Width = " & CStr(Me.Width - Me.ClientSize.Width))
        '----------------------------------------
    End Sub
    '***********************************************************************
    Private Sub frmMain_Move(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Move
        '仧仧仧儊僀儞儂乕儉偵偺傒愝掕偡傞僐乕僪仧仧仧丂儊僀儞儂乕儉撪偐傜偺傒屇傃弌偟傑偡丅
        gggint = zzAppIniFileOp(2, gggstrary)
    End Sub
    '***********************************************************************
    Private Sub frmMain_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint
        'Static mmm As Integer
        'mmm = mmm + 1 : qqqqq("仭仭frmMain_Paint " + Format(mmm, "0000") + vbCrLf)
        'If gm傾僾儕廔椆偡傞 Then qqqqq("gm傾僾儕廔椆偡傞  in frmMain_Paint()")
        If mCall_In_frmMain_ResizeEnd Then Return
        If pct儊僀儞.Visible = False Then Return
        Call gm傾僾儕屌桳僋儔僗.aafrmMain_Paint()
    End Sub
    '***********************************************************************
#End Region

#Region "儊僯儏乕僀儀儞僩"
    '***********************************************************************
    Friend Sub mn1game僎乕儉僋儕傾_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僎乕儉僋儕傾.Click
        If gm傾僾儕廔椆偡傞 Then Exit Sub
        Call aa僎乕儉僋儕傾(False)
    End Sub
    '***********************************************************************
    Private Sub mn1game僎乕儉梡僼傽僀儖傪愝掕_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僎乕儉梡僼傽僀儖傪愝掕.Click
        If gm傾僾儕廔椆偡傞 Then Return
        Call gm傾僾儕屌桳僋儔僗.aa僼傽僀儖夋憸僎乕儉梡DlgShow(Me)
    End Sub
    '***********************************************************************
    Private Sub mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_1.Click, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_2.Click, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_3.Click, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_4.Click, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_5.Click
        If gm傾僾儕屌桳僋儔僗 Is Nothing Then Return
        Dim index As Integer = IIf(sender.Equals(mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_1), 1, IIf(sender.Equals(mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_2), 2, IIf(sender.Equals(mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_3), 3, IIf(sender.Equals(mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_4), 4, IIf(sender.Equals(mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_5), 5, 0)))))
        If index = 0 Then Return
        gggstr = gm傾僾儕屌桳僋儔僗.aa_mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_Click(index)
    End Sub
    '***********************************************************************
    Private Sub mn1game僎乕儉梡僼傽僀儖傪師偵愗傝懼偊_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僎乕儉梡僼傽僀儖傪師偵愗傝懼偊.Click
        If gm傾僾儕廔椆偡傞 Then Return
        gggbol = gm傾僾儕屌桳僋儔僗.p僞僀儅乕偱偺夋憸帺摦愗傝懼偊_師偺夋憸偵愗傝懼偊
    End Sub
    '***********************************************************************
    Private Sub mn1game僇乕僪枃悢巜掕Do_1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僇乕僪枃悢巜掕Do_1.Click, mn1game僇乕僪枃悢巜掕Do_2.Click, mn1game僇乕僪枃悢巜掕Do_3.Click, mn1game僇乕僪枃悢巜掕Do_4.Click, mn1game僇乕僪枃悢巜掕Do_5.Click, mn1game僇乕僪枃悢巜掕Do_6.Click
        If gm傾僾儕廔椆偡傞 Then Return
        Dim index As Integer = IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_1), 1, IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_2), 2, IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_3), 3, IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_4), 4, IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_5), 5, IIf(sender.Equals(mn1game僇乕僪枃悢巜掕Do_6), 6, 0))))))
        If index = 0 Then Return
        gggstr = gm傾僾儕屌桳僋儔僗.p尰嵼偺僇乕僪枃悢_RW(gco僾儘僷MenuClick, CStr(index))
        pct儊僀儞.Visible = True
        pctBmp.Visible = False
    End Sub
    Friend Sub mn1game僇乕僪枃悢巜掕Do_ClickCOM(ByVal index As Integer)
        Dim sender As Object = IIf(index = 1, mn1game僇乕僪枃悢巜掕Do_1, IIf(index = 2, mn1game僇乕僪枃悢巜掕Do_2, IIf(index = 3, mn1game僇乕僪枃悢巜掕Do_3, IIf(index = 4, mn1game僇乕僪枃悢巜掕Do_4, IIf(index = 5, mn1game僇乕僪枃悢巜掕Do_5, IIf(index = 6, mn1game僇乕僪枃悢巜掕Do_6, Nothing))))))
        If sender Is Nothing Then Return
        Call mn1game僇乕僪枃悢巜掕Do_1_Click(sender, Nothing)
    End Sub
    '***********************************************************************
    Private Sub mn1game僸儞僩昞帵Do_1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僸儞僩昞帵Do_1.Click, mn1game僸儞僩昞帵Do_2.Click, mn1game僸儞僩昞帵Do_3.Click, mn1game僸儞僩昞帵Do_4.Click
        If gm傾僾儕廔椆偡傞 Then Return
        If sender.Equals(mn1game僸儞僩昞帵Do_1) Or sender.Equals(mn1game僸儞僩昞帵Do_2) Or sender.Equals(mn1game僸儞僩昞帵Do_3) Or sender.Equals(mn1game僸儞僩昞帵Do_4) Then
            Dim Tagstr As String = sender.tag
            gggstr = gm傾僾儕屌桳僋儔僗.p僸儞僩昞帵_RW(gco僾儘僷MenuClick, Tagstr)
        Else
            Return
        End If
    End Sub
    '***********************************************************************
    Private Sub mn1game僗僀僗僀傪帺摦幚峴_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game僗僀僗僀傪帺摦幚峴.Click
        If gm傾僾儕廔椆偡傞 Then Return
        mn1game僗僀僗僀傪帺摦幚峴.Checked = Not mn1game僗僀僗僀傪帺摦幚峴.Checked
        oo僗僀僗僀.p僗僀僗僀傪帺摦幚峴 = mn1game僗僀僗僀傪帺摦幚峴.Checked
    End Sub
    '***********************************************************************
    Friend Sub mn1game偙偺傾僾儕傪廔椆_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn1game偙偺傾僾儕傪廔椆.Click
        gm傾僾儕廔椆偡傞 = True : Me.Close()
    End Sub
    '***********************************************************************
    Private Sub mn3opt僆僾僔儑儞愝掕Dlg昞帵_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn3opt僆僾僔儑儞愝掕Dlg昞帵.Click
        If gm傾僾儕廔椆偡傞 Then Return
        Call gm傾僾儕屌桳僋儔僗.mn3opt僆僾僔儑儞愝掕Dlg_Load_1_Disposed_2(1, Me)
    End Sub
    '***********************************************************************
    Private Sub mn3opt僒僂儞僪愝掕Dlg昞帵_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn3opt僒僂儞僪愝掕Dlg昞帵.Click
        If gm傾僾儕廔椆偡傞 Then Return
        Call gm傾僾儕屌桳僋儔僗.mn3opt僒僂儞僪愝掕Dlg_Load_1_Disposed_2(1, Me)
    End Sub
    '***********************************************************************
    Private Sub mn9help巊梡曽朄傾僾儕愱梡_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn9help巊梡曽朄傾僾儕愱梡.Click
        Call 巐frmHelpWnd.aaHelpWndShow(Me, GMCOM傾僾儕僞僀僩儖("") & "丂偺僿儖僾", gm僿儖僾僼傽僀儖, gm僿儖僾僼傽僀儖CSS)
    End Sub
    '***********************************************************************
    Private Sub mn9help巊梡曽朄Web僽儔僂僓_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn9help巊梡曽朄Web僽儔僂僓.Click
        gggbol = 嘳FileRunOrFolderShow(CInt(Me.Handle), 0, gm僿儖僾僼傽僀儖)
    End Sub
    '***********************************************************************
    Private Sub mn9help僶乕僕儑儞忣曬_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn9help僶乕僕儑儞忣曬.Click
        Dim dlg As New 巐frmDlgAbout
        dlg.AboutBoxShow(Me) '
        dlg.Dispose()
    End Sub
    '***********************************************************************
    Private Sub mnbbb嵟戝壔_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mnbbb嵟戝壔.Click
        mmLoading = True
        gggbol = 嘳Forms_嵟戝壔_昗弨壔_儊僯儏乕憖嶌(1, Me, mnbbb嵟戝壔)
        mmLoading = False
        Call frmMain_ResizeEnd(Nothing, Nothing)
    End Sub
    '***********************************************************************
    Private Sub tim僎乕儉帪娫_Tick(ByVal sender As Object, ByVal e As System.EventArgs) Handles tim僎乕儉帪娫.Tick
        With gm傾僾儕屌桳僋儔僗
            gggbol = 僎乕儉僨乕僞乕昞帵(1, .p尰嵼偺僇乕僪枃悢, .p僇乕僪枃悢_尰嵼偺巆傝枃悢)
        End With
    End Sub
    Friend Function 僎乕儉僨乕僞乕昞帵(ByVal r奐巒_0_搑拞_1_廔椆_2_弶婜壔_3 As Integer, ByVal m僗僞乕僩僇乕僪枃悢 As Integer, ByVal m尰嵼偺巆傝僇乕僪枃悢 As Integer) As Boolean
        Dim v As Boolean = (r奐巒_0_搑拞_1_廔椆_2_弶婜壔_3 = 2)
        If r奐巒_0_搑拞_1_廔椆_2_弶婜壔_3 <> 1 Then gggbol = GMCOM_僎乕儉寢壥僷僱儖昞帵_愗懼(IIf(v, 1, 2))
        Return 嘳僎乕儉枃悢_宱夁帪娫_昞帵張棟(r奐巒_0_搑拞_1_廔椆_2_弶婜壔_3, tim僎乕儉帪娫, m僗僞乕僩僇乕僪枃悢, m尰嵼偺巆傝僇乕僪枃悢, mnttt帪娫枃悢, lblMaisuu, lblTime)
    End Function
    '***********************************************************************
#End Region

#Region "僗僀僗僀幚峴儊僯儏乕孮"
    '***********************************************************************
    Private Sub mn8suiyula_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8suiyula.Click
        '    'no op
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀偲儐儔儐儔傪幚峴_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀偲儐儔儐儔傪幚峴.Click
        If pp僎乕儉幚峴拞 Then gggint = aa僎乕儉僋儕傾(False)
        Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(3, True)
        '********************************************************************************
        If gm傾僾儕廔椆偡傞 Then Exit Sub
        '********************************************************************************
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀偲儐儔儐儔偡傋偰掆巭_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀偲儐儔儐儔偡傋偰掆巭.Click
        If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(3, False)
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀幚峴_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀幚峴.Click
        If pp僎乕儉幚峴拞 Then gggint = aa僎乕儉僋儕傾(False)
        Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(1, True)
        '********************************************************************************
        If gm傾僾儕廔椆偡傞 Then Exit Sub
        '********************************************************************************
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀掆巭_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀掆巭.Click
        Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(1, False)
    End Sub
    '***********************************************************************
    Friend Sub mn8儐儔儐儔幚峴_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8儐儔儐儔幚峴.Click
        If pp僎乕儉幚峴拞 Then gggint = aa僎乕儉僋儕傾(False)
        Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(2, True)
    End Sub
    '***********************************************************************
    Friend Sub mn8儐儔儐儔掆巭_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8儐儔儐儔掆巭.Click
        Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(2, False)
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀偲儐儔儐儔傪昞帵_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀偲儐儔儐儔傪昞帵.Click
        Call gm僗僀僗僀嫟梡僋儔僗.aa僗僀僗僀儐儔儐儔愝掕Dlg_Load_1_Disposed_2(1, Me) 'gggbol = oo僗僀僗僀.aa僗僀僗僀儐儔儐儔愝掕DlgShow(Me)
    End Sub
    '***********************************************************************
    Friend Sub mn8僗僀僗僀夋憸傪愝掕_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8僗僀僗僀夋憸傪愝掕.Click
        Call oo僗僀僗僀.aa僼傽僀儖夋憸僗僀僗僀梡DlgShow(Me)
    End Sub
    '***********************************************************************
    Private Sub mn8偙偺傾僾儕傪廔椆_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles mn8偙偺傾僾儕傪廔椆.Click
        Call mn1game偙偺傾僾儕傪廔椆_Click(Nothing, Nothing)
    End Sub
    '***********************************************************************
#End Region

#Region "僞僀儅乕僀儀儞僩"
    '***********************************************************************
    Friend Function aaTim僇乕僪宆曄峏_EnabledSet(ByVal en As Boolean) As Boolean
        'no op 僟儈乕娭悢
    End Function
    '***********************************************************************
    Private Sub TimEventOn_Tick(ByVal sender As Object, ByVal e As System.EventArgs) Handles TimEventOn.Tick
        TimEventOn.Enabled = False
        Select Case TimEventOnStr
            Case "mn8僗僀僗僀偲儐儔儐儔傪幚峴_Click" : Call mn8僗僀僗僀偲儐儔儐儔傪幚峴_Click(Nothing, Nothing)
            Case "frmMain_SizeChanged" : Call frmMain_ResizeEnd(Nothing, Nothing) ': qqqqq("TimEventOn_Tick  frmMain_SizeChanged")
            Case ""
        End Select
        TimEventOnStr = ""
    End Sub
    '***********************************************************************
#End Region

#Region "僂僀儞僪僂偵僪儔僢僌僪儘僢僾偱僼傽僀儖捛壛"
    '***********************************************************************
    Private Sub frmMain_DragOver(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles Me.DragOver
        If oo僗僀僗僀.DlgFile僗僀僗僀梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟傕掆巭偟偰偄傞 Then Return
        gggbol = 嘳OLEDragDrop僼傽僀儖僀儀儞僩_Drag_Is_巜掕EXT_IN(e, gco奼挘巕廤_夋憸)
    End Sub
    Private Sub frmMain_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles Me.DragDrop
        If oo僗僀僗僀.DlgFile僗僀僗僀梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟傕掆巭偟偰偄傞 Then Return
        Call zzMe_or_pctBmp_or_pct儊僀儞_DragDrop_COM(sender, e)
    End Sub
    '***********************************************************************
    Private Sub pctBmp_DragOver(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles pctBmp.DragOver
        If gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then Return
        gggbol = 嘳OLEDragDrop僼傽僀儖僀儀儞僩_Drag_Is_巜掕EXT_IN(e, gco奼挘巕廤_夋憸)
    End Sub
    Private Sub pctBmp_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles pctBmp.DragDrop
        If gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then Return
        Call zzMe_or_pctBmp_or_pct儊僀儞_DragDrop_COM(sender, e)
    End Sub
    '***********************************************************************
    Private Sub pct儊僀儞_DragOver(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles pct儊僀儞.DragOver
        If gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then Return
        gggbol = 嘳OLEDragDrop僼傽僀儖僀儀儞僩_Drag_Is_巜掕EXT_IN(e, gco奼挘巕廤_夋憸)
    End Sub
    Private Sub pct儊僀儞_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles pct儊僀儞.DragDrop
        If gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡.lbl嶍彍儌乕僪.Visible = True Then Return
        If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then Return
        Call zzMe_or_pctBmp_or_pct儊僀儞_DragDrop_COM(sender, e)
    End Sub
    '***********************************************************************
    Private Sub zzMe_or_pctBmp_or_pct儊僀儞_DragDrop_COM(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs)
        Dim wFolders_0_Ubound() As String = {""} : Dim wFiles() As String = {""} : Dim wDrpX_inControl, wDrpY_inControl As Integer
        If 嘳OLEDragDrop僼傽僀儖僀儀儞僩(3, sender, e, wFolders_0_Ubound, wFiles, wDrpX_inControl, wDrpY_inControl) Then
            'qqqqq("wFolders_0_Ubound") : For a = 0 To UBound(wFolders_0_Ubound) : qqqqq(wFolders_0_Ubound(a)) : Next
            'qqqqq("wFiles_0_Ubound") : For a = 0 To UBound(wFiles_0_Ubound) : qqqqq(wFiles_0_Ubound(a)) : Next
            'qqqqq(CStr(wDrpX_inControl))
            'qqqqq(CStr(wDrpY_inControl))
        End If
        Dim max As Integer = 嘳暥攝楍傪僛儘儀乕僗偐傜堧儀乕僗偵偡傞(wFiles)
        gmFlag_On_OLEDropFile = True
        If sender.Equals(Me) Then
            gggbol = oo僗僀僗僀.DlgFile僗僀僗僀梡.aa僼傽僀儖夋憸堦枃傪儕僗僩偵捛壛_on_DRAG_DROP_in_frmMain(wFiles)
        Else
            gggbol = gm傾僾儕屌桳僋儔僗.DlgFile僎乕儉梡.aa僼傽僀儖夋憸堦枃傪儕僗僩偵捛壛_on_DRAG_DROP_in_frmMain(wFiles)
        End If
        gmFlag_On_OLEDropFile = False
    End Sub
    '***********************************************************************
#End Region

#Region "pct儊僀儞_儅僂僗僀儀儞僩"
    '***********************************************************************
    Private Function pct儊僀儞_儅僂僗僀儀儞僩_COM(ByRef EventFromWnd As Boolean, ByRef MouseOp As Integer, ByRef Button As Integer, ByRef X As Integer, ByRef Y As Integer, ByVal OnLoopCardID As Integer) As Boolean
        pct儊僀儞_儅僂僗僀儀儞僩_COM = gm傾僾儕屌桳僋儔僗.aa僼僅乕儉儅僂僗僀儀儞僩張棟(EventFromWnd, MouseOp, Button, X, Y, OnLoopCardID)
    End Function
    Private Sub pct儊僀儞_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles pct儊僀儞.MouseDown
        Call pct儊僀儞_儅僂僗僀儀儞僩_COM(True, 1, e.Button, e.X, e.Y, 0)
    End Sub
    Private Sub pct儊僀儞_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles pct儊僀儞.MouseMove
        Call pct儊僀儞_儅僂僗僀儀儞僩_COM(True, 2, e.Button, e.X, e.Y, 0)
    End Sub
    Private Sub pct儊僀儞_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles pct儊僀儞.MouseUp
        Call pct儊僀儞_儅僂僗僀儀儞僩_COM(True, 3, e.Button, e.X, e.Y, 0)
    End Sub
    '***********************************************************************
    Private Sub pctBmp_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles pctBmp.MouseUp
        Call pct儊僀儞_儅僂僗僀儀儞僩_COM(True, 3, e.Button, e.X, e.Y, 0)
    End Sub
    '***********************************************************************
#End Region

#Region "aa奜晹偲偺僀儞僞僼僃僀僗"
    '***********************************************************************
    Friend Function aa儊僯儏乕僆僽僕僃愝掕(ByRef 僾儘僷 As String, ByRef 儊僰() As ToolStripMenuItem, ByRef 壓 As Integer, ByRef 忋 As Integer) As Boolean
        Dim a As Integer
        Select Case 僾儘僷
            '--------------------------------------------------------------------------------
            '2021/06/25  摿暿偵捛壛偟偨僾儘僷
            Case "p僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘"
                a = 嘳儊僯儏乕攝楍嶌惉_1_20(儊僰, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_1, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_2, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_3, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_4, mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘Do_5)
                壓 = 1 : 忋 = UBound(儊僰)

            Case "p尰嵼偺僇乕僪枃悢"
                a = 嘳儊僯儏乕攝楍嶌惉_1_20(儊僰, mn1game僇乕僪枃悢巜掕Do_1, mn1game僇乕僪枃悢巜掕Do_2, mn1game僇乕僪枃悢巜掕Do_3, mn1game僇乕僪枃悢巜掕Do_4, mn1game僇乕僪枃悢巜掕Do_5, mn1game僇乕僪枃悢巜掕Do_6)
                壓 = 1 : 忋 = UBound(儊僰)

            Case "p僗僀僗僀傪帺摦幚峴"
                a = 嘳儊僯儏乕攝楍嶌惉_1_20(儊僰, mn1game僗僀僗僀傪帺摦幚峴)
                壓 = 1 : 忋 = UBound(儊僰)

            Case "p僸儞僩昞帵"
                a = 嘳儊僯儏乕攝楍嶌惉_1_20(儊僰, mn1game僸儞僩昞帵Do_1, mn1game僸儞僩昞帵Do_2, mn1game僸儞僩昞帵Do_3, mn1game僸儞僩昞帵Do_4)
                壓 = 1 : 忋 = UBound(儊僰)
        End Select
        Return True
        ' ''--------------------------------------------------------------------------------
        ''Static m As Long
        ''m = m + 1: If m = 1 Then qqqqq "************************************":
        ''qqqqq "aa儊僯... " + 僾儘僷 + "   " + CStr(壓) + " - " + CStr(忋)
        ' ''--------------------------------------------------------------------------------
    End Function
    '***********************************************************************
    Friend Function aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒(ByRef 僾儘僷僐儅儞僪 As Integer, ByRef ini攝楍() As String) As Boolean
        Dim CurIDX As Integer
        Dim 攝楍忋尷 As Integer = 1000
        Select Case 僾儘僷僐儅儞僪
            Case gco僾儘僷弶婜壔
                'no item
            Case gco僾儘僷iniRD
                For CurIDX = 1 To UBound(ini攝楍)
                    'no item
                Next
            Case gco僾儘僷iniWR
                ReDim ini攝楍(攝楍忋尷)
                CurIDX = 0
                CurIDX = CurIDX + 1 : If CurIDX <= 攝楍忋尷 Then ini攝楍(CurIDX) = "" Else GoTo exitpos_gco僾儘僷iniWR
                CurIDX = CurIDX + 1 : If CurIDX <= 攝楍忋尷 Then ini攝楍(CurIDX) = "Use In aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒()" Else GoTo exitpos_gco僾儘僷iniWR
                CurIDX = CurIDX + 1 : If CurIDX <= 攝楍忋尷 Then ini攝楍(CurIDX) = "仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 DataStart 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭" Else GoTo exitpos_gco僾儘僷iniWR
                'no item
        End Select
        gggbol = gm傾僾儕屌桳僋儔僗.aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒sub(僾儘僷僐儅儞僪, ini攝楍, CurIDX)
        gggbol = oo僗僀僗僀.aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒sub(僾儘僷僐儅儞僪, ini攝楍, CurIDX)
        gggbol = oo儐儔儐儔.aa僾儘僷僥傿弶婜壔_INI撉弌偟彂崬傒sub(僾儘僷僐儅儞僪, ini攝楍, CurIDX)
        If 僾儘僷僐儅儞僪 = gco僾儘僷iniWR Then
            CurIDX = CurIDX + 1 : If CurIDX <= 攝楍忋尷 Then ini攝楍(CurIDX) = "仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭 DataEnd 仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭"
            CurIDX = CurIDX + 1 : If CurIDX <= 攝楍忋尷 Then ini攝楍(CurIDX) = ""
            ReDim Preserve ini攝楍(CurIDX)
        End If
exitpos_gco僾儘僷iniWR:
        ReDim Preserve ini攝楍(CurIDX) : Return True
        Return True
    End Function
    '***********************************************************************
    Friend Function aa_僗僀僗僀傪帺摦幚峴_傕偟愝掕偝傟偰偄傟偽() As Boolean
        If oo僗僀僗僀.p僗僀僗僀傪帺摦幚峴 Then
            TimEventOnStr = "mn8僗僀僗僀偲儐儔儐儔傪幚峴_Click" : TimEventOn.Enabled = True
            Return True
        End If
        Return False
    End Function
    '***********************************************************************
    Friend Function aa_傕偟僎乕儉幚峴拞側傜偽嵞昤夋(ByVal 嫟桳偺偨傔偺僟儈乕侾 As Integer, ByRef 嫟桳偺偨傔偺僟儈乕俀 As Boolean, ByRef 嫟桳偺偨傔偺僟儈乕俁 As Boolean) As Boolean
        If pp僎乕儉幚峴拞 Then
            Return gm傾僾儕屌桳僋儔僗.aa僇乕僪偺攝抲偲嵞昤夋(3)
        End If
        Return False
    End Function
    '***********************************************************************
    Friend Function aa僎乕儉僋儕傾(ByVal 嫟梡偺偨傔偺tmp堷悢 As Boolean) As Boolean
        Return gm傾僾儕屌桳僋儔僗.aa僎乕儉僋儕傾
    End Function
    '***********************************************************************
#End Region

#Region "pnl僎乕儉寢壥"
    '***************************************************************************************************************
    'pnl僎乕儉寢壥丂偺丂昞帵丂傪丂徚偡
    Private Sub pnl僎乕儉寢壥_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles pnl僎乕儉寢壥.Click, lblHed.Click, lblMaisuu.Click, lblTime.Click
        gggbol = GMCOM_僎乕儉寢壥僷僱儖昞帵_愗懼(2)
    End Sub
#End Region

#Region "僾儘僷僥傿"

    'no item

#End Region

#Region "僀儀儞僩gAppEventMaker 僀儀儞僩"
    '***********************************************************************
    Private Sub 僀儀儞僩gAppEventMaker_Dlg僗僀僗僀偲儐儔儐儔傪昞帵徚嫀(ByVal r昞帵True徚嫀False As Boolean) Handles 僀儀儞僩gAppEventMaker.Dlg僗僀僗僀偲儐儔儐儔傪昞帵徚嫀
        If (gAppEventMaker.僼僅乕儉偺昞帵徚嫀_愝掕偲庢摼(0, gmDlg僗僀僗僀儐儔儐儔) = False) And r昞帵True徚嫀False Then
            Call mn8僗僀僗僀偲儐儔儐儔傪昞帵_Click(Nothing, Nothing)
        End If
    End Sub
    '***********************************************************************
    Private Sub 僀儀儞僩gAppEventMaker_僎乕儉奐巒偲掆巭(ByVal r奐巒True掆巭False As Boolean, ByRef wOptionRetStr As String) Handles 僀儀儞僩gAppEventMaker.僎乕儉奐巒偲掆巭
        If r奐巒True掆巭False Then
            If pp僗僀僗僀僼儔僼儔_偄偢傟偐偁傞偄偼椉曽_傪幚峴拞 Then
                Call oo僗僀僗僀.aa僗僀僗僀偲儐儔儐儔幚峴偺奐巒偲掆巭(5, False)
            End If
        Else
        End If
        mn1game僎乕儉僋儕傾.Enabled = r奐巒True掆巭False
        mn1game僎乕儉梡僼傽僀儖傪師偵愗傝懼偊.Enabled = r奐巒True掆巭False
        mn8suiyula.Visible = Not r奐巒True掆巭False
    End Sub
    '***********************************************************************
    Private Sub 僀儀儞僩gAppEventMaker_僗僀僗僀偲儐儔儐儔奐巒偲掆巭() Handles 僀儀儞僩gAppEventMaker.僗僀僗僀偲儐儔儐儔奐巒偲掆巭
        If gm傾僾儕廔椆偡傞 Then Return
        gggbol = 僀儀儞僩gAppEventMaker.僗僀僗僀偲儐儔儐儔奐巒偲掆巭_嫟捠張棟("frmMain", mn8僗僀僗僀偲儐儔儐儔傪幚峴, mn8僗僀僗僀偲儐儔儐儔偡傋偰掆巭, _
                                   mn8僗僀僗僀幚峴, mn8僗僀僗僀掆巭, mn8儐儔儐儔幚峴, mn8儐儔儐儔掆巭, _
                                   mn8僗僀僗僀偲儐儔儐儔傪昞帵, mn8僗僀僗僀夋憸傪愝掕)
        '--------------------------------------
        Dim ev As Boolean = pp僗僀僗僀僼儔僼儔_偄偢傟傕掆巭偟偰偄傞
        mn1game.Visible = ev
        mn3opt.Visible = ev
        mn9help僶乕僕儑儞忣曬.Enabled = ev
        '--------------------------------------
        If ev Then
            gggbol = aa僎乕儉僋儕傾(False)
        End If
        gggbol = GMCOM_僎乕儉僨乕僞乕儊僯儏乕_VisibleSet(mnttt帪娫枃悢)
    End Sub
    '***********************************************************************
    Private Sub 僀儀儞僩gAppEventMaker_僗僀僗僀儐儔儐儔夋憸昞帵ONOFF(ByVal r夋憸昞帵OnOff As Boolean) Handles 僀儀儞僩gAppEventMaker.僗僀僗僀儐儔儐儔夋憸昞帵ONOFF
        If gm傾僾儕廔椆偡傞 Then Return
        '------------------------------------------------------------------
        mn8僗僀僗僀偲儐儔儐儔傪幚峴.Enabled = r夋憸昞帵OnOff
        mn8儐儔儐儔幚峴.Enabled = r夋憸昞帵OnOff
    End Sub
    '***********************************************************************
    Private Sub 僀儀儞僩gAppEventMaker_僼僅乕儉偺昞帵偲徚嫀(ByVal r僼僅乕儉柤ID As Integer, ByVal r昞帵True徚嫀False As Boolean) Handles 僀儀儞僩gAppEventMaker.僼僅乕儉偺昞帵偲徚嫀
        If gm傾僾儕廔椆偡傞 Then
            qqqqq("gm傾僾儕廔椆偡傞 Event_僼僅乕儉偺昞帵偲徚嫀()" + Me.Name)
            Return
        End If
        Dim b1 As Boolean = Not r昞帵True徚嫀False
        Select Case r僼僅乕儉柤ID
            Case gmDlgFile僎乕儉梡
                mn1game僎乕儉梡僼傽僀儖傪愝掕.Enabled = b1
                mn1game僎乕儉梡僼傽僀儖偺愗傝懼偊帪娫娫妘.Enabled = b1
                mn1game僎乕儉梡僼傽僀儖傪師偵愗傝懼偊.Enabled = b1 And pp僎乕儉幚峴拞
            Case gmDlg僆僾僔儑儞愝掕
                mn3opt僆僾僔儑儞愝掕Dlg昞帵.Enabled = b1
            Case gmDlg僒僂儞僪愝掕
                mn3opt僒僂儞僪愝掕Dlg昞帵.Enabled = b1
            Case gmDlg僗僀僗僀儐儔儐儔
                mn8僗僀僗僀偲儐儔儐儔傪昞帵.Enabled = b1
            Case gmDlgFile僗僀僗僀梡
                mn8僗僀僗僀夋憸傪愝掕.Enabled = b1
        End Select
    End Sub
    '***********************************************************************
#End Region

#Region "仭仭嫟梡僋儔僗傪巊梡偡傞偨傔偺僟儈乕娭悢"
    '***********************************************************************
    Friend Sub mn8僗僀僗僀梡僇乕僪宆傪愝掕_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        '嫟梡僋儔僗傪巊梡偡傞偨傔偺僟儈乕娭悢
    End Sub
    Friend Function p僗僀僗僀僇乕僪宆儕乕僕儑儞傪嶌傞(ByVal op As Integer, ByRef 夋暆 As Integer, ByRef 夋崅 As Integer, ByRef 榞暆幚悺 As Integer, ByRef Rgn夋 As Integer, ByRef Rgn榞 As Integer) As Boolean
        '嫟梡僋儔僗傪巊梡偡傞偨傔偺僟儈乕娭悢
        Return False
    End Function
    Friend Property p僗僀僗僀僇乕僪僀儊乕僕() As Integer
        '嫟梡僋儔僗傪巊梡偡傞偨傔偺僟儈乕娭悢
        Get
        End Get
        Set(ByVal Value As Integer)
        End Set
    End Property
    '***********************************************************************
#End Region

End Class





