コード例 #1
0
 public static frmUpdatePlaybackTime GetChildInstance()
 {
     if (m_SChildform == null)
     {
         m_SChildform = new frmUpdatePlaybackTime();
     }
     return m_SChildform;
 }
コード例 #2
0
ファイル: frmConfiguration.cs プロジェクト: facchinm/SiRFLive
        private void configDataGridView_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            e_configParams @params;
            int rowIndex = e.RowIndex;
            string source = this.configDataGridView.Rows[rowIndex].Cells[0].Value.ToString().Trim();
            string inStr = this.configDataGridView.Rows[rowIndex].Cells[1].Value.ToString().Trim();
            switch (source)
            {
                case "PLAYBACK_FILES":
                case "HOST_APP":
                case "PATCH_FILE":
                    @params = e_configParams.E_CONFIG_UNKNOWN;
                    if (!(source == "HOST_APP"))
                    {
                        if (source == "PATCH_FILE")
                        {
                            @params = e_configParams.E_PATCH_NAME;
                        }
                        else
                        {
                            @params = e_configParams.E_PLAYBACK_FILES;
                        }
                        break;
                    }
                    @params = e_configParams.E_HOST_APP_NAME;
                    break;

                case "BASE_TEST_LOG":
                case "HOST_APP_DIR":
                {
                    e_configParams type = e_configParams.E_CONFIG_UNKNOWN;
                    if (!(source == "HOST_APP_DIR"))
                    {
                        type = e_configParams.E_LOG_DIR;
                    }
                    else
                    {
                        type = e_configParams.E_HOST_DIR;
                    }
                    frmUpdateTestLogDir dir = frmUpdateTestLogDir.GetChildInstance(type);
                    if (dir.IsDisposed)
                    {
                        dir = new frmUpdateTestLogDir(type);
                    }
                    this.currentSelectCellIdx = 1;
                    this.currentSelectRowIdx = rowIndex;
                    dir.updateParent += new frmUpdateTestLogDir.updateParentEventHandler(this.updateConfigList);
                    dir.MdiParent = base.MdiParent;
                    dir.ShowDialog();
                    return;
                }
                case "PLAY_TIME_LISTS":
                {
                    frmUpdatePlaybackTime time = frmUpdatePlaybackTime.GetChildInstance();
                    if (time.IsDisposed)
                    {
                        time = new frmUpdatePlaybackTime();
                    }
                    this.currentSelectCellIdx = 1;
                    this.currentSelectRowIdx = rowIndex;
                    time.updateParent += new frmUpdatePlaybackTime.updateParentEventHandler(this.updateConfigList);
                    time.MdiParent = base.MdiParent;
                    time.ShowDialog();
                    return;
                }
                case "SIGNAL_SOURCE":
                case "ATTEN_SOURCE":
                case "POWER_SOURCE":
                {
                    frmComboBoxSelection selection = frmComboBoxSelection.GetChildInstance(source);
                    if (selection.IsDisposed)
                    {
                        selection = new frmComboBoxSelection(source);
                    }
                    this.currentSelectCellIdx = 1;
                    this.currentSelectRowIdx = rowIndex;
                    selection.updateParent += new frmComboBoxSelection.updateParentEventHandler(this.updateConfigList);
                    selection.MdiParent = base.MdiParent;
                    selection.ShowDialog();
                    return;
                }
                default:
                    if (this.configDataGridView.Rows[rowIndex].HeaderCell.Value.ToString() == "RX_SETUP")
                    {
                        frmReceiverConfig config = frmReceiverConfig.GetChildInstance();
                        if (config.IsDisposed)
                        {
                            config = new frmReceiverConfig();
                        }
                        config.MdiParent = base.MdiParent;
                        config.updateParent += new frmReceiverConfig.updateParentEventHandler(this.updateConfigList);
                        config.ShowDialog();
                    }
                    return;
            }
            frmUpdatePbFiles childInstance = frmUpdatePbFiles.GetChildInstance(@params, inStr);
            if (childInstance.IsDisposed)
            {
                childInstance = new frmUpdatePbFiles(@params, inStr);
            }
            this.currentSelectCellIdx = 1;
            this.currentSelectRowIdx = rowIndex;
            childInstance.updateParent += new frmUpdatePbFiles.updateParentEventHandler(this.updateConfigList);
            childInstance.MdiParent = base.MdiParent;
            childInstance.ShowDialog();
        }
コード例 #3
0
ファイル: frmStationSetup.cs プロジェクト: facchinm/SiRFLive
 private void updatePlaybackTime_Click(object sender, EventArgs e)
 {
     frmUpdatePlaybackTime childInstance = frmUpdatePlaybackTime.GetChildInstance();
     if (childInstance.IsDisposed)
     {
         childInstance = new frmUpdatePlaybackTime();
     }
     childInstance.updateParent += new frmUpdatePlaybackTime.updateParentEventHandler(this.updatePlaybackTimeList);
     childInstance.MdiParent = base.MdiParent;
     childInstance.ShowDialog();
 }
コード例 #4
0
 protected override void OnClosed(EventArgs e)
 {
     m_SChildform = null;
 }
コード例 #5
0
 private void frmUpdatePbTimeCancelBut_Click(object sender, EventArgs e)
 {
     base.Close();
     m_SChildform = null;
 }