コード例 #1
0
ファイル: SaveRecordDlg.cs プロジェクト: zszqwe/dp2
        void InitialDp2Protocol()
        {
            if (m_bDp2Initialized == true)
            {
                return;
            }

            if (this.GetDp2SearchParam == null)
            {
                throw new Exception("Getdp2SearchParamEventHandle not set");
            }

            GetDp2SearchParamEventArgs e = new GetDp2SearchParamEventArgs();

            this.GetDp2SearchParam(this, e);

            if (this.MainForm != null &&
                this.dp2ResTree1.cfgCache == null)
            {
                this.dp2ResTree1.cfgCache = this.MainForm.cfgCache;
            }

            // 初始化dp2协议相关参数
            this.dp2ResTree1.stopManager = e.MainForm.stopManager;
            this.dp2ResTree1.Servers     = e.MainForm.Servers;  // 引用
#if OLD_CHANNEL
            this.dp2ResTree1.Channels = e.dp2Channels;
#endif
            this.dp2ResTree1.ChannelManager = Program.MainForm;

            this.dp2ResTree1.EnabledIndices = new int[] { dp2ResTree.RESTYPE_DB };
            this.dp2ResTree1.Fill(null);

            m_bDp2Initialized = true;
        }
コード例 #2
0
ファイル: SaveRecordDlg.cs プロジェクト: renyh1013/dp2
        void InitialDp2Protocol()
        {
            if (m_bDp2Initialized == true)
                return;

            if (this.GetDp2SearchParam == null)
            {
                throw new Exception("Getdp2SearchParamEventHandle not set");
            }

            GetDp2SearchParamEventArgs e = new GetDp2SearchParamEventArgs();
            this.GetDp2SearchParam(this, e);

            if (this.MainForm != null
    && this.dp2ResTree1.cfgCache == null)
                this.dp2ResTree1.cfgCache = this.MainForm.cfgCache;

            // 初始化dp2协议相关参数
            this.dp2ResTree1.stopManager = e.MainForm.stopManager;
            this.dp2ResTree1.Servers = e.MainForm.Servers;	// 引用
            this.dp2ResTree1.Channels = e.dp2Channels;
            this.dp2ResTree1.EnabledIndices = new int[] { dp2ResTree.RESTYPE_DB };
            this.dp2ResTree1.Fill(null);

            m_bDp2Initialized = true;
        }
コード例 #3
0
ファイル: AmazonSearchForm.cs プロジェクト: paopaofeng/dp2
        void dlg_GetDp2SearchParam(object sender, GetDp2SearchParamEventArgs e)
        {
            dp2SearchForm dp2_searchform = this.GetDp2SearchForm();

            e.dp2Channels = dp2_searchform.Channels;
            e.MainForm = this.m_mainForm;
        }
コード例 #4
0
ファイル: dp2SearchForm.cs プロジェクト: renyh1013/dp2
 void dlg_GetDp2SearchParam(object sender, GetDp2SearchParamEventArgs e)
 {
     e.dp2Channels = this.Channels;
     e.MainForm = this.MainForm;
 }