// Decompiled with JetBrains decompiler
// Type: HPG_68D.ChannelMsg
// Assembly: HPG-68D, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: 530C99A8-8EEF-42C8-8A74-66FDE7B322C3
// Assembly location: C:\Program Files (x86)\HONGKAIDE\HPG-68D\HPG-68D.exe

using HPG_68D.My;
using Microsoft.VisualBasic;
using Microsoft.VisualBasic.CompilerServices;
using System;
using System.Collections;
using System.ComponentModel;
using System.Diagnostics;
using System.Drawing;
using System.Runtime.CompilerServices;
using System.Windows.Forms;


namespace HPG_68D
{
  [DesignerGenerated]
  public class ChannelMsg : Form
  {
    private static ArrayList __ENCList = new ArrayList();
    private IContainer components;
    [AccessedThroughProperty("ChannelMsgDataGridView")]
    private DataGridView _ChannelMsgDataGridView;
    [AccessedThroughProperty("Panel1")]
    private Panel _Panel1;
    [AccessedThroughProperty("Button3")]
    private Button _Button3;
    [AccessedThroughProperty("Button2")]
    private Button _Button2;
    [AccessedThroughProperty("Button1")]
    private Button _Button1;
    [AccessedThroughProperty("Button信道编辑")]
    private Button _Button信道编辑;
    [AccessedThroughProperty("ColumnRxFreq")]
    private DataGridViewTextBoxColumn _ColumnRxFreq;
    [AccessedThroughProperty("Column差频方向")]
    private DataGridViewComboBoxColumn _Column差频方向;
    [AccessedThroughProperty("ColumnTxFreq")]
    private DataGridViewTextBoxColumn _ColumnTxFreq;
    [AccessedThroughProperty("Column亚音解码类型")]
    private DataGridViewComboBoxColumn _Column亚音解码类型;
    [AccessedThroughProperty("Column亚音解码")]
    private DataGridViewComboBoxColumn _Column亚音解码;
    [AccessedThroughProperty("Column亚音编码类型")]
    private DataGridViewComboBoxColumn _Column亚音编码类型;
    [AccessedThroughProperty("Column亚音编码")]
    private DataGridViewComboBoxColumn _Column亚音编码;
    [AccessedThroughProperty("Column发射功率")]
    private DataGridViewComboBoxColumn _Column发射功率;
    [AccessedThroughProperty("Column扫描添加")]
    private DataGridViewComboBoxColumn _Column扫描添加;
    [AccessedThroughProperty("Column带宽")]
    private DataGridViewComboBoxColumn _Column带宽;
    [AccessedThroughProperty("Column可选信令")]
    private DataGridViewComboBoxColumn _Column可选信令;
    [AccessedThroughProperty("Column更多")]
    private DataGridViewButtonColumn _Column更多;

    [DebuggerNonUserCode]
    static ChannelMsg()
    {
    }

    [DebuggerNonUserCode]
    public ChannelMsg()
    {
      this.Deactivate += new EventHandler(this.ChannelMsg_Deactivate);
      this.FormClosing += new FormClosingEventHandler(this.ChannelMsg_FormClosing);
      this.Load += new EventHandler(this.ChannelMsg_Load);
      ChannelMsg.__ENCList.Add((object) new WeakReference((object) this));
      this.InitializeComponent();
    }

    [DebuggerNonUserCode]
    protected override void Dispose(bool disposing)
    {
      if (disposing && this.components != null)
        this.components.Dispose();
      base.Dispose(disposing);
    }

    [DebuggerStepThrough]
    private void InitializeComponent()
    {
      DataGridViewCellStyle gridViewCellStyle1 = new DataGridViewCellStyle();
      DataGridViewCellStyle gridViewCellStyle2 = new DataGridViewCellStyle();
      ComponentResourceManager componentResourceManager = new ComponentResourceManager(typeof (ChannelMsg));
      DataGridViewCellStyle gridViewCellStyle3 = new DataGridViewCellStyle();
      DataGridViewCellStyle gridViewCellStyle4 = new DataGridViewCellStyle();
      DataGridViewCellStyle gridViewCellStyle5 = new DataGridViewCellStyle();
      DataGridViewCellStyle gridViewCellStyle6 = new DataGridViewCellStyle();
      this.ChannelMsgDataGridView = new DataGridView();
      this.Panel1 = new Panel();
      this.Button3 = new Button();
      this.Button2 = new Button();
      this.Button1 = new Button();
      this.Button信道编辑 = new Button();
      this.ColumnRxFreq = new DataGridViewTextBoxColumn();
      this.Column差频方向 = new DataGridViewComboBoxColumn();
      this.ColumnTxFreq = new DataGridViewTextBoxColumn();
      this.Column亚音解码类型 = new DataGridViewComboBoxColumn();
      this.Column亚音解码 = new DataGridViewComboBoxColumn();
      this.Column亚音编码类型 = new DataGridViewComboBoxColumn();
      this.Column亚音编码 = new DataGridViewComboBoxColumn();
      this.Column发射功率 = new DataGridViewComboBoxColumn();
      this.Column扫描添加 = new DataGridViewComboBoxColumn();
      this.Column带宽 = new DataGridViewComboBoxColumn();
      this.Column可选信令 = new DataGridViewComboBoxColumn();
      this.Column更多 = new DataGridViewButtonColumn();
      ((ISupportInitialize) this.ChannelMsgDataGridView).BeginInit();
      this.Panel1.SuspendLayout();
      this.SuspendLayout();
      this.ChannelMsgDataGridView.AllowUserToAddRows = false;
      this.ChannelMsgDataGridView.AllowUserToDeleteRows = false;
      this.ChannelMsgDataGridView.AllowUserToResizeColumns = false;
      this.ChannelMsgDataGridView.AllowUserToResizeRows = false;
      gridViewCellStyle1.Alignment = DataGridViewContentAlignment.MiddleCenter;
      this.ChannelMsgDataGridView.AlternatingRowsDefaultCellStyle = gridViewCellStyle1;
      gridViewCellStyle2.Alignment = DataGridViewContentAlignment.MiddleCenter;
      gridViewCellStyle2.BackColor = SystemColors.Control;
      gridViewCellStyle2.Font = new Font("宋体", 9f, FontStyle.Regular, GraphicsUnit.Point, (byte) 134);
      gridViewCellStyle2.ForeColor = SystemColors.WindowText;
      gridViewCellStyle2.SelectionBackColor = SystemColors.Highlight;
      gridViewCellStyle2.SelectionForeColor = SystemColors.HighlightText;
      gridViewCellStyle2.WrapMode = DataGridViewTriState.True;
      this.ChannelMsgDataGridView.ColumnHeadersDefaultCellStyle = gridViewCellStyle2;
      componentResourceManager.ApplyResources((object) this.ChannelMsgDataGridView, "ChannelMsgDataGridView");
      this.ChannelMsgDataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
      this.ChannelMsgDataGridView.Columns.AddRange((DataGridViewColumn) this.ColumnRxFreq, (DataGridViewColumn) this.Column差频方向, (DataGridViewColumn) this.ColumnTxFreq, (DataGridViewColumn) this.Column亚音解码类型, (DataGridViewColumn) this.Column亚音解码, (DataGridViewColumn) this.Column亚音编码类型, (DataGridViewColumn) this.Column亚音编码, (DataGridViewColumn) this.Column发射功率, (DataGridViewColumn) this.Column扫描添加, (DataGridViewColumn) this.Column带宽, (DataGridViewColumn) this.Column可选信令, (DataGridViewColumn) this.Column更多);
      this.ChannelMsgDataGridView.Name = "ChannelMsgDataGridView";
      gridViewCellStyle3.Alignment = DataGridViewContentAlignment.MiddleCenter;
      gridViewCellStyle3.BackColor = SystemColors.Control;
      gridViewCellStyle3.Font = new Font("宋体", 9f, FontStyle.Regular, GraphicsUnit.Point, (byte) 134);
      gridViewCellStyle3.ForeColor = SystemColors.WindowText;
      gridViewCellStyle3.SelectionBackColor = SystemColors.Highlight;
      gridViewCellStyle3.SelectionForeColor = SystemColors.HighlightText;
      gridViewCellStyle3.WrapMode = DataGridViewTriState.True;
      this.ChannelMsgDataGridView.RowHeadersDefaultCellStyle = gridViewCellStyle3;
      this.ChannelMsgDataGridView.RowHeadersWidthSizeMode = DataGridViewRowHeadersWidthSizeMode.DisableResizing;
      gridViewCellStyle4.Alignment = DataGridViewContentAlignment.MiddleCenter;
      this.ChannelMsgDataGridView.RowsDefaultCellStyle = gridViewCellStyle4;
      this.ChannelMsgDataGridView.RowTemplate.Height = 23;
      componentResourceManager.ApplyResources((object) this.Panel1, "Panel1");
      this.Panel1.BorderStyle = BorderStyle.Fixed3D;
      this.Panel1.Controls.Add((Control) this.ChannelMsgDataGridView);
      this.Panel1.Name = "Panel1";
      componentResourceManager.ApplyResources((object) this.Button3, "Button3");
      this.Button3.Name = "Button3";
      this.Button3.UseVisualStyleBackColor = true;
      componentResourceManager.ApplyResources((object) this.Button2, "Button2");
      this.Button2.Name = "Button2";
      this.Button2.UseVisualStyleBackColor = true;
      componentResourceManager.ApplyResources((object) this.Button1, "Button1");
      this.Button1.Name = "Button1";
      this.Button1.UseVisualStyleBackColor = true;
      componentResourceManager.ApplyResources((object) this.Button信道编辑, "Button信道编辑");
      this.Button信道编辑.Name = "Button信道编辑";
      this.Button信道编辑.UseVisualStyleBackColor = true;
      gridViewCellStyle5.Alignment = DataGridViewContentAlignment.MiddleCenter;
      this.ColumnRxFreq.DefaultCellStyle = gridViewCellStyle5;
      componentResourceManager.ApplyResources((object) this.ColumnRxFreq, "ColumnRxFreq");
      this.ColumnRxFreq.MaxInputLength = 9;
      this.ColumnRxFreq.Name = "ColumnRxFreq";
      this.ColumnRxFreq.Resizable = DataGridViewTriState.False;
      this.ColumnRxFreq.SortMode = DataGridViewColumnSortMode.NotSortable;
      this.Column差频方向.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column差频方向, "Column差频方向");
      this.Column差频方向.Items.AddRange((object) "OFF", (object) "DUP -", (object) "DUP +");
      this.Column差频方向.Name = "Column差频方向";
      componentResourceManager.ApplyResources((object) this.ColumnTxFreq, "ColumnTxFreq");
      this.ColumnTxFreq.MaxInputLength = 9;
      this.ColumnTxFreq.Name = "ColumnTxFreq";
      this.ColumnTxFreq.SortMode = DataGridViewColumnSortMode.NotSortable;
      this.Column亚音解码类型.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column亚音解码类型, "Column亚音解码类型");
      this.Column亚音解码类型.Items.AddRange((object) "OFF", (object) "TONE", (object) "CTCSS", (object) "DCS");
      this.Column亚音解码类型.Name = "Column亚音解码类型";
      this.Column亚音解码.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column亚音解码, "Column亚音解码");
      this.Column亚音解码.Items.AddRange((object) "OFF", (object) "67.0", (object) "69.3", (object) "71.9", (object) "74.4", (object) "77.0", (object) "79.7", (object) "82.5", (object) "85.4", (object) "88.5", (object) "91.5", (object) "94.8", (object) "97.4", (object) "100.0", (object) "103.5", (object) "107.2", (object) "110.9", (object) "114.8", (object) "118.8", (object) "123.0", (object) "127.3", (object) "131.8", (object) "136.5", (object) "141.3", (object) "146.2", (object) "151.4", (object) "156.7", (object) "159.8", (object) "162.2", (object) "165.5", (object) "167.9", (object) "171.3", (object) "173.8", (object) "177.3", (object) "179.9", (object) "183.5", (object) "186.2", (object) "189.9", (object) "192.8", (object) "196.6", (object) "199.5", (object) "203.5", (object) "206.5", (object) "210.7", (object) "218.1", (object) "225.7", (object) "229.1", (object) "233.6", (object) "241.8", (object) "250.3", (object) "254.1", (object) "D017N", (object) "D023N", (object) "D025N", (object) "D026N", (object) "D031N", (object) "D032N", (object) "D036N", (object) "D043N", (object) "D047N", (object) "D050N", (object) "D051N", (object) "D053N", (object) "D054N", (object) "D065N", (object) "D071N", (object) "D072N", (object) "D073N", (object) "D074N", (object) "D114N", (object) "D115N", (object) "D116N", (object) "D122N", (object) "D125N", (object) "D131N", (object) "D132N", (object) "D134N", (object) "D143N", (object) "D145N", (object) "D152N", (object) "D155N", (object) "D156N", (object) "D162N", (object) "D165N", (object) "D172N", (object) "D174N", (object) "D205N", (object) "D212N", (object) "D223N", (object) "D225N", (object) "D226N", (object) "D243N", (object) "D244N", (object) "D245N", (object) "D246N", (object) "D251N", (object) "D252N", (object) "D255N", (object) "D261N", (object) "D263N", (object) "D265N", (object) "D266N", (object) "D271N", (object) "D274N", (object) "D306N", (object) "D311N", (object) "D315N", (object) "D325N", (object) "D331N", (object) "D332N", (object) "D343N", (object) "D346N", (object) "D351N", (object) "D356N", (object) "D364N", (object) "D365N", (object) "D371N", (object) "D411N", (object) "D412N", (object) "D413N", (object) "D423N", (object) "D431N", (object) "D432N", (object) "D445N", (object) "D446N", (object) "D452N", (object) "D454N", (object) "D455N", (object) "D462N", (object) "D464N", (object) "D465N", (object) "D466N", (object) "D503N", (object) "D506N", (object) "D516N", (object) "D523N", (object) "D526N", (object) "D532N", (object) "D546N", (object) "D565N", (object) "D606N", (object) "D612N", (object) "D624N", (object) "D627N", (object) "D631N", (object) "D632N", (object) "D645N", (object) "D654N", (object) "D662N", (object) "D664N", (object) "D703N", (object) "D712N", (object) "D723N", (object) "D731N", (object) "D732N", (object) "D734N", (object) "D743N", (object) "D754N", (object) "D017I", (object) "D023I", (object) "D025I", (object) "D026I", (object) "D031I", (object) "D032I", (object) "D036I", (object) "D043I", (object) "D047I", (object) "D050I", (object) "D051I", (object) "D053I", (object) "D054I", (object) "D065I", (object) "D071I", (object) "D072I", (object) "D073I", (object) "D074I", (object) "D114I", (object) "D115I", (object) "D116I", (object) "D122I", (object) "D125I", (object) "D131I", (object) "D132I", (object) "D134I", (object) "D143I", (object) "D145I", (object) "D152I", (object) "D155I", (object) "D156I", (object) "D162I", (object) "D165I", (object) "D172I", (object) "D174I", (object) "D205I", (object) "D212I", (object) "D223I", (object) "D225I", (object) "D226I", (object) "D243I", (object) "D244I", (object) "D245I", (object) "D246I", (object) "D251I", (object) "D252I", (object) "D255I", (object) "D261I", (object) "D263I", (object) "D265I", (object) "D266I", (object) "D271I", (object) "D274I", (object) "D306I", (object) "D311I", (object) "D315I", (object) "D325I", (object) "D331I", (object) "D332I", (object) "D343I", (object) "D346I", (object) "D351I", (object) "D356I", (object) "D364I", (object) "D365I", (object) "D371I", (object) "D411I", (object) "D412I", (object) "D413I", (object) "D423I", (object) "D431I", (object) "D432I", (object) "D445I", (object) "D446I", (object) "D452I", (object) "D454I", (object) "D455I", (object) "D462I", (object) "D464I", (object) "D465I", (object) "D466I", (object) "D503I", (object) "D506I", (object) "D516I", (object) "D523I", (object) "D526I", (object) "D532I", (object) "D546I", (object) "D565I", (object) "D606I", (object) "D612I", (object) "D624I", (object) "D627I", (object) "D631I", (object) "D632I", (object) "D645I", (object) "D654I", (object) "D662I", (object) "D664I", (object) "D703I", (object) "D712I", (object) "D723I", (object) "D731I", (object) "D732I", (object) "D734I", (object) "D743I", (object) "D754I");
      this.Column亚音解码.Name = "Column亚音解码";
      this.Column亚音编码类型.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column亚音编码类型, "Column亚音编码类型");
      this.Column亚音编码类型.Items.AddRange((object) "OFF", (object) "TONE", (object) "CTCSS", (object) "DCS");
      this.Column亚音编码类型.Name = "Column亚音编码类型";
      this.Column亚音编码.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column亚音编码, "Column亚音编码");
      this.Column亚音编码.Items.AddRange((object) "OFF", (object) "67.0", (object) "69.3", (object) "71.9", (object) "74.4", (object) "77.0", (object) "79.7", (object) "82.5", (object) "85.4", (object) "88.5", (object) "91.5", (object) "94.8", (object) "97.4", (object) "100.0", (object) "103.5", (object) "107.2", (object) "110.9", (object) "114.8", (object) "118.8", (object) "123.0", (object) "127.3", (object) "131.8", (object) "136.5", (object) "141.3", (object) "146.2", (object) "151.4", (object) "156.7", (object) "159.8", (object) "162.2", (object) "165.5", (object) "167.9", (object) "171.3", (object) "173.8", (object) "177.3", (object) "179.9", (object) "183.5", (object) "186.2", (object) "189.9", (object) "192.8", (object) "196.6", (object) "199.5", (object) "203.5", (object) "206.5", (object) "210.7", (object) "218.1", (object) "225.7", (object) "229.1", (object) "233.6", (object) "241.8", (object) "250.3", (object) "254.1", (object) "D017N", (object) "D023N", (object) "D025N", (object) "D026N", (object) "D031N", (object) "D032N", (object) "D036N", (object) "D043N", (object) "D047N", (object) "D050N", (object) "D051N", (object) "D053N", (object) "D054N", (object) "D065N", (object) "D071N", (object) "D072N", (object) "D073N", (object) "D074N", (object) "D114N", (object) "D115N", (object) "D116N", (object) "D122N", (object) "D125N", (object) "D131N", (object) "D132N", (object) "D134N", (object) "D143N", (object) "D145N", (object) "D152N", (object) "D155N", (object) "D156N", (object) "D162N", (object) "D165N", (object) "D172N", (object) "D174N", (object) "D205N", (object) "D212N", (object) "D223N", (object) "D225N", (object) "D226N", (object) "D243N", (object) "D244N", (object) "D245N", (object) "D246N", (object) "D251N", (object) "D252N", (object) "D255N", (object) "D261N", (object) "D263N", (object) "D265N", (object) "D266N", (object) "D271N", (object) "D274N", (object) "D306N", (object) "D311N", (object) "D315N", (object) "D325N", (object) "D331N", (object) "D332N", (object) "D343N", (object) "D346N", (object) "D351N", (object) "D356N", (object) "D364N", (object) "D365N", (object) "D371N", (object) "D411N", (object) "D412N", (object) "D413N", (object) "D423N", (object) "D431N", (object) "D432N", (object) "D445N", (object) "D446N", (object) "D452N", (object) "D454N", (object) "D455N", (object) "D462N", (object) "D464N", (object) "D465N", (object) "D466N", (object) "D503N", (object) "D506N", (object) "D516N", (object) "D523N", (object) "D526N", (object) "D532N", (object) "D546N", (object) "D565N", (object) "D606N", (object) "D612N", (object) "D624N", (object) "D627N", (object) "D631N", (object) "D632N", (object) "D645N", (object) "D654N", (object) "D662N", (object) "D664N", (object) "D703N", (object) "D712N", (object) "D723N", (object) "D731N", (object) "D732N", (object) "D734N", (object) "D743N", (object) "D754N", (object) "D017I", (object) "D023I", (object) "D025I", (object) "D026I", (object) "D031I", (object) "D032I", (object) "D036I", (object) "D043I", (object) "D047I", (object) "D050I", (object) "D051I", (object) "D053I", (object) "D054I", (object) "D065I", (object) "D071I", (object) "D072I", (object) "D073I", (object) "D074I", (object) "D114I", (object) "D115I", (object) "D116I", (object) "D122I", (object) "D125I", (object) "D131I", (object) "D132I", (object) "D134I", (object) "D143I", (object) "D145I", (object) "D152I", (object) "D155I", (object) "D156I", (object) "D162I", (object) "D165I", (object) "D172I", (object) "D174I", (object) "D205I", (object) "D212I", (object) "D223I", (object) "D225I", (object) "D226I", (object) "D243I", (object) "D244I", (object) "D245I", (object) "D246I", (object) "D251I", (object) "D252I", (object) "D255I", (object) "D261I", (object) "D263I", (object) "D265I", (object) "D266I", (object) "D271I", (object) "D274I", (object) "D306I", (object) "D311I", (object) "D315I", (object) "D325I", (object) "D331I", (object) "D332I", (object) "D343I", (object) "D346I", (object) "D351I", (object) "D356I", (object) "D364I", (object) "D365I", (object) "D371I", (object) "D411I", (object) "D412I", (object) "D413I", (object) "D423I", (object) "D431I", (object) "D432I", (object) "D445I", (object) "D446I", (object) "D452I", (object) "D454I", (object) "D455I", (object) "D462I", (object) "D464I", (object) "D465I", (object) "D466I", (object) "D503I", (object) "D506I", (object) "D516I", (object) "D523I", (object) "D526I", (object) "D532I", (object) "D546I", (object) "D565I", (object) "D606I", (object) "D612I", (object) "D624I", (object) "D627I", (object) "D631I", (object) "D632I", (object) "D645I", (object) "D654I", (object) "D662I", (object) "D664I", (object) "D703I", (object) "D712I", (object) "D723I", (object) "D731I", (object) "D732I", (object) "D734I", (object) "D743I", (object) "D754I");
      this.Column亚音编码.Name = "Column亚音编码";
      this.Column发射功率.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column发射功率, "Column发射功率");
      this.Column发射功率.Items.AddRange((object) "高", (object) "低", (object) "中");
      this.Column发射功率.Name = "Column发射功率";
      this.Column扫描添加.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
      this.Column扫描添加.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column扫描添加, "Column扫描添加");
      this.Column扫描添加.Items.AddRange((object) "是", (object) "否");
      this.Column扫描添加.Name = "Column扫描添加";
      this.Column带宽.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column带宽, "Column带宽");
      this.Column带宽.Items.AddRange((object) "宽带(25K)", (object) "宽带(20K)", (object) "窄带(12.5K)");
      this.Column带宽.Name = "Column带宽";
      this.Column可选信令.DisplayStyle = DataGridViewComboBoxDisplayStyle.Nothing;
      componentResourceManager.ApplyResources((object) this.Column可选信令, "Column可选信令");
      this.Column可选信令.Items.AddRange((object) "无", (object) "DTMF", (object) "2-Tone", (object) "5-Tone");
      this.Column可选信令.Name = "Column可选信令";
      gridViewCellStyle6.Alignment = DataGridViewContentAlignment.MiddleCenter;
      gridViewCellStyle6.BackColor = Color.FromArgb(224, 224, 224);
      gridViewCellStyle6.ForeColor = Color.Red;
      this.Column更多.DefaultCellStyle = gridViewCellStyle6;
      this.Column更多.FlatStyle = FlatStyle.Popup;
      componentResourceManager.ApplyResources((object) this.Column更多, "Column更多");
      this.Column更多.Name = "Column更多";
      this.Column更多.Resizable = DataGridViewTriState.False;
      this.Column更多.Text = ">>";
      this.Column更多.UseColumnTextForButtonValue = true;
      componentResourceManager.ApplyResources((object) this, "$this");
      this.AutoScaleMode = AutoScaleMode.Font;
      this.Controls.Add((Control) this.Button信道编辑);
      this.Controls.Add((Control) this.Button3);
      this.Controls.Add((Control) this.Button2);
      this.Controls.Add((Control) this.Button1);
      this.Controls.Add((Control) this.Panel1);
      this.DoubleBuffered = true;
      this.Name = nameof (ChannelMsg);
      ((ISupportInitialize) this.ChannelMsgDataGridView).EndInit();
      this.Panel1.ResumeLayout(false);
      this.ResumeLayout(false);
    }

    internal virtual DataGridView ChannelMsgDataGridView
    {
      [DebuggerNonUserCode] get => this._ChannelMsgDataGridView;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        if (this._ChannelMsgDataGridView != null)
        {
          this._ChannelMsgDataGridView.CellValidating -= new DataGridViewCellValidatingEventHandler(this.ChannelMsgDataGridView_CellValidating);
          this._ChannelMsgDataGridView.EditingControlShowing -= new DataGridViewEditingControlShowingEventHandler(this.ChannelMsgDataGridView_EditingControlShowing);
          this._ChannelMsgDataGridView.CellEndEdit -= new DataGridViewCellEventHandler(this.ChannelMsgDataGridView_CellEndEdit);
          this._ChannelMsgDataGridView.CellMouseClick -= new DataGridViewCellMouseEventHandler(this.ChannelMsgDataGridView_CellMouseClick);
          this._ChannelMsgDataGridView.RowPostPaint -= new DataGridViewRowPostPaintEventHandler(this.ChannelMsgDataGridView_RowPostPaint);
        }
        this._ChannelMsgDataGridView = value;
        if (this._ChannelMsgDataGridView == null)
          return;
        this._ChannelMsgDataGridView.CellValidating += new DataGridViewCellValidatingEventHandler(this.ChannelMsgDataGridView_CellValidating);
        this._ChannelMsgDataGridView.EditingControlShowing += new DataGridViewEditingControlShowingEventHandler(this.ChannelMsgDataGridView_EditingControlShowing);
        this._ChannelMsgDataGridView.CellEndEdit += new DataGridViewCellEventHandler(this.ChannelMsgDataGridView_CellEndEdit);
        this._ChannelMsgDataGridView.CellMouseClick += new DataGridViewCellMouseEventHandler(this.ChannelMsgDataGridView_CellMouseClick);
        this._ChannelMsgDataGridView.RowPostPaint += new DataGridViewRowPostPaintEventHandler(this.ChannelMsgDataGridView_RowPostPaint);
      }
    }

    internal virtual Panel Panel1
    {
      [DebuggerNonUserCode] get => this._Panel1;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set => this._Panel1 = value;
    }

    internal virtual Button Button3
    {
      [DebuggerNonUserCode] get => this._Button3;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Button3 = value;
      }
    }

    internal virtual Button Button2
    {
      [DebuggerNonUserCode] get => this._Button2;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Button2 = value;
      }
    }

    internal virtual Button Button1
    {
      [DebuggerNonUserCode] get => this._Button1;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        if (this._Button1 != null)
          this._Button1.Click -= new EventHandler(this.Button1_Click);
        this._Button1 = value;
        if (this._Button1 == null)
          return;
        this._Button1.Click += new EventHandler(this.Button1_Click);
      }
    }

    internal virtual Button Button信道编辑
    {
      [DebuggerNonUserCode] get => this._Button信道编辑;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        if (this._Button信道编辑 != null)
          this._Button信道编辑.Click -= new EventHandler(this.Button信道编辑_Click);
        this._Button信道编辑 = value;
        if (this._Button信道编辑 == null)
          return;
        this._Button信道编辑.Click += new EventHandler(this.Button信道编辑_Click);
      }
    }

    internal virtual DataGridViewTextBoxColumn ColumnRxFreq
    {
      [DebuggerNonUserCode] get => this._ColumnRxFreq;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._ColumnRxFreq = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column差频方向
    {
      [DebuggerNonUserCode] get => this._Column差频方向;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column差频方向 = value;
      }
    }

    internal virtual DataGridViewTextBoxColumn ColumnTxFreq
    {
      [DebuggerNonUserCode] get => this._ColumnTxFreq;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._ColumnTxFreq = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column亚音解码类型
    {
      [DebuggerNonUserCode] get => this._Column亚音解码类型;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column亚音解码类型 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column亚音解码
    {
      [DebuggerNonUserCode] get => this._Column亚音解码;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column亚音解码 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column亚音编码类型
    {
      [DebuggerNonUserCode] get => this._Column亚音编码类型;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column亚音编码类型 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column亚音编码
    {
      [DebuggerNonUserCode] get => this._Column亚音编码;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column亚音编码 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column发射功率
    {
      [DebuggerNonUserCode] get => this._Column发射功率;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column发射功率 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column扫描添加
    {
      [DebuggerNonUserCode] get => this._Column扫描添加;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column扫描添加 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column带宽
    {
      [DebuggerNonUserCode] get => this._Column带宽;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column带宽 = value;
      }
    }

    internal virtual DataGridViewComboBoxColumn Column可选信令
    {
      [DebuggerNonUserCode] get => this._Column可选信令;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column可选信令 = value;
      }
    }

    internal virtual DataGridViewButtonColumn Column更多
    {
      [DebuggerNonUserCode] get => this._Column更多;
      [DebuggerNonUserCode, MethodImpl(MethodImplOptions.Synchronized)] set
      {
        this._Column更多 = value;
      }
    }

    public void ChannelMsg_Deactivate(object sender, EventArgs e)
    {
      this.ChannelMsgDataGridView.EndEdit();
      int num = checked (this.ChannelMsgDataGridView.RowCount - 1);
      int i = 0;
      while (i <= num)
      {
        this.SetData_CHMsg(i);
        checked { ++i; }
      }
    }

    private void ChannelMsg_FormClosing(object sender, FormClosingEventArgs e)
    {
      MyProject.Forms.MDIParent1.信道信息CToolStripMenuItem.Checked = false;
    }

    public void ChannelMsg_Load(object sender, EventArgs e)
    {
      MyProject.Forms.MDIParent1.信道信息CToolStripMenuItem.Checked = true;
      this.ChannelMsgDataGridView.RowCount = 516;
      if (Operators.CompareString(publicva.Language, "zh-CN", false) == 0)
      {
        this.ChannelMsgDataGridView.TopLeftHeaderCell.Value = (object) "信道";
        this.Column发射功率.Items.Clear();
        this.Column发射功率.Items.AddRange((object) "高", (object) "低", (object) "中");
        this.Column扫描添加.Items.Clear();
        this.Column扫描添加.Items.AddRange((object) "是", (object) "否");
        this.Column带宽.Items.Clear();
        this.Column带宽.Items.AddRange((object) "宽带(25K)", (object) "宽带(20K)", (object) "窄带(12.5K)");
        this.Column可选信令.Items.Clear();
        this.Column可选信令.Items.AddRange((object) "无", (object) "DTMF", (object) "2-Tone", (object) "5-Tone");
      }
      else
      {
        this.ChannelMsgDataGridView.TopLeftHeaderCell.Value = (object) "CH";
        this.Column发射功率.Items.Clear();
        this.Column发射功率.Items.AddRange((object) "High", (object) "Low", (object) "Middle");
        this.Column扫描添加.Items.Clear();
        this.Column扫描添加.Items.AddRange((object) "Yes", (object) "No");
        this.Column带宽.Items.Clear();
        this.Column带宽.Items.AddRange((object) "Wide(25K)", (object) "Wide(20K)", (object) "Narrow(12.5K)");
        this.Column可选信令.Items.Clear();
        this.Column可选信令.Items.AddRange((object) "None", (object) "DTMF", (object) "2-Tone", (object) "5-Tone");
      }
      int num = checked (this.ChannelMsgDataGridView.RowCount - 1);
      int i = 0;
      while (i <= num)
      {
        this.GetStr_CHMsg(i);
        checked { ++i; }
      }
    }

    private void ChannelMsgDataGridView_CellEndEdit(object sender, DataGridViewCellEventArgs e)
    {
      int rowIndex = this.ChannelMsgDataGridView.CurrentCell.RowIndex;
      int columnIndex = this.ChannelMsgDataGridView.CurrentCell.ColumnIndex;
      int num = columnIndex;
      if (num == this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].ColumnIndex)
      {
        if (Operators.ConditionalCompareObjectNotEqual(this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].Value, (object) "", false))
        {
          string str = Conversions.ToString(this.JudgeInputRxFreq(Conversions.ToString(this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].Value), true));
          this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].Value = (object) str;
          if (Operators.ConditionalCompareObjectEqual(this.ChannelMsgDataGridView["ColumnTxFreq", rowIndex].Value, (object) "", false))
          {
            if (Operators.CompareString(str, "", false) == 0)
              this.Clr_Channel(rowIndex);
            else
              this.Init_Channel(str, rowIndex);
          }
          else if (Operators.CompareString(str, "", false) == 0)
            this.Clr_Channel(rowIndex);
        }
        else
          this.Clr_Channel(rowIndex);
      }
      else if (num == this.ChannelMsgDataGridView["ColumnTxFreq", rowIndex].ColumnIndex)
      {
        string str = Conversions.ToString(this.JudgeInputTxFreq(Conversions.ToString(this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].Value), Conversions.ToString(this.ChannelMsgDataGridView["ColumnTxFreq", rowIndex].Value), true));
        this.ChannelMsgDataGridView["ColumnTxFreq", rowIndex].Value = (object) str;
      }
      else if (num == this.ChannelMsgDataGridView["Column亚音解码类型", rowIndex].ColumnIndex)
      {
        switch (this.Column亚音解码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音解码类型", rowIndex].Value)))
        {
          case 0:
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[0]);
            break;
          case 1:
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[9]);
            break;
          case 2:
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[9]);
            break;
          case 3:
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[52]);
            break;
        }
      }
      else if (num == this.ChannelMsgDataGridView["Column亚音解码", rowIndex].ColumnIndex)
      {
        switch (this.Column亚音解码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音解码类型", rowIndex].Value)))
        {
          case 0:
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[0]);
            break;
          case 1:
            if (!Versioned.IsNumeric(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value)) | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 7))));
              break;
            }
            break;
          case 2:
            if (!Versioned.IsNumeric(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value)) | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 7))));
              break;
            }
            break;
          case 3:
            if (Operators.CompareString("D", this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value.ToString().Substring(0, 1), false) != 0 | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 7))));
            }
            break;
        }
      }
      else if (num == this.ChannelMsgDataGridView["Column亚音编码类型", rowIndex].ColumnIndex)
      {
        switch (this.Column亚音编码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音编码类型", rowIndex].Value)))
        {
          case 0:
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[0]);
            break;
          case 1:
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[9]);
            break;
          case 2:
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[9]);
            break;
          case 3:
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[52]);
            break;
        }
      }
      else if (num == this.ChannelMsgDataGridView["Column亚音编码", rowIndex].ColumnIndex)
      {
        switch (this.Column亚音编码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音编码类型", rowIndex].Value)))
        {
          case 0:
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[0]);
            break;
          case 1:
            if (!Versioned.IsNumeric(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value)) | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 9))));
              break;
            }
            break;
          case 2:
            if (!Versioned.IsNumeric(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value)) | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 9))));
              break;
            }
            break;
          case 3:
            if (Operators.CompareString("D", this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value.ToString().Substring(0, 1), false) != 0 | publicva.ToneValueValidatingDIS)
            {
              publicva.ToneValueValidatingDIS = false;
              this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(Conversions.ToInteger(Operators.AddObject(this.Get_CHAddress(rowIndex), (object) 9))));
            }
            break;
        }
      }
      if (columnIndex == this.ChannelMsgDataGridView["Column更多", 0].ColumnIndex)
        return;
      this.SetData_CHMsg(rowIndex);
      if (MyProject.Forms.MDIParent1.JudgeIsFormLoaded((Form) MyProject.Forms.ChannelEditForm) && rowIndex == MyProject.Forms.ChannelEditForm.ComboBox编辑信道号.SelectedIndex)
        MyProject.Forms.ChannelEditForm.GetStr_CHMsg(rowIndex);
      if (MyProject.Forms.MDIParent1.JudgeIsFormLoaded((Form) MyProject.Forms.ScanFuncMsgForm))
        MyProject.Forms.ScanFuncMsgForm.SetControl_PRICHList();
      MyProject.Forms.TypeFuncMsgForm.TypeFuncMsgForm_Load(RuntimeHelpers.GetObjectValue(sender), (EventArgs) e);
      MyProject.Forms.SOSMsgForm.SOSMsgForm_Load(RuntimeHelpers.GetObjectValue(sender), (EventArgs) e);
    }

    private void ChannelMsgDataGridView_EditingControlShowing(
      object sender,
      DataGridViewEditingControlShowingEventArgs e)
    {
      if (this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["ColumnRxFreq", 0].ColumnIndex | this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["ColumnTxFreq", 0].ColumnIndex)
      {
        DataGridViewTextBoxEditingControl boxEditingControl = new DataGridViewTextBoxEditingControl();
        boxEditingControl = (DataGridViewTextBoxEditingControl) e.Control;
        e.Control.KeyPress += new KeyPressEventHandler(this.Cells_KeyPress);
      }
      else
      {
        if (!(this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音解码", 0].ColumnIndex | this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音编码", 0].ColumnIndex))
          return;
        DataGridViewComboBoxEditingControl boxEditingControl = new DataGridViewComboBoxEditingControl();
        DataGridViewComboBoxEditingControl control = (DataGridViewComboBoxEditingControl) e.Control;
        control.DropDownStyle = ComboBoxStyle.DropDown;
        control.MaxLength = 5;
        e.Control.KeyPress += new KeyPressEventHandler(this.ComboBoxCells_KeyPress);
      }
    }

    private void Cells_KeyPress(object sender, KeyPressEventArgs e)
    {
      if (char.IsDigit(e.KeyChar) | e.KeyChar == '\b' | Operators.CompareString(Conversions.ToString(e.KeyChar), ".", false) == 0)
        e.Handled = false;
      else
        e.Handled = true;
    }

    private void ComboBoxCells_KeyPress(object sender, KeyPressEventArgs e)
    {
      if (Operators.CompareString(Conversions.ToString(e.KeyChar), "D", false) == 0 | char.IsDigit(e.KeyChar) | e.KeyChar == '\b' | Operators.CompareString(Conversions.ToString(e.KeyChar), "N", false) == 0 | Operators.CompareString(Conversions.ToString(e.KeyChar), "I", false) == 0 | e.KeyChar == '.' | Operators.CompareString(Conversions.ToString(e.KeyChar), "d", false) == 0 | Operators.CompareString(Conversions.ToString(e.KeyChar), "n", false) == 0 | Operators.CompareString(Conversions.ToString(e.KeyChar), "i", false) == 0)
      {
        if (Operators.CompareString(Conversions.ToString(e.KeyChar), "d", false) == 0 | Operators.CompareString(Conversions.ToString(e.KeyChar), "n", false) == 0 | Operators.CompareString(Conversions.ToString(e.KeyChar), "i", false) == 0)
          e.KeyChar = char.ToUpper(e.KeyChar);
        e.Handled = false;
      }
      else
        e.Handled = true;
    }

    private void ChannelMsgDataGridView_CellValidating(
      object sender,
      DataGridViewCellValidatingEventArgs e)
    {
      int rowIndex = this.ChannelMsgDataGridView.CurrentCell.RowIndex;
      if (this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音解码", 0].ColumnIndex | this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音编码", 0].ColumnIndex)
      {
        publicva.ToneValueValidatingDIS = false;
        if (Conversions.ToBoolean(Operators.AndObject(Operators.CompareObjectNotEqual(e.FormattedValue, (object) "", false), (object) (this.Column亚音解码.Items.IndexOf(RuntimeHelpers.GetObjectValue(e.FormattedValue)) != 0))))
        {
          string str;
          if (Operators.CompareString(e.FormattedValue.ToString().Substring(0, 1), "D", false) == 0)
          {
            if (e.FormattedValue.ToString().Length != 5)
            {
              publicva.ToneValueValidatingDIS = true;
              return;
            }
            if (!(Operators.CompareString(e.FormattedValue.ToString().Substring(4, 1), "N", false) == 0 | Operators.CompareString(e.FormattedValue.ToString().Substring(4, 1), "I", false) == 0))
            {
              publicva.ToneValueValidatingDIS = true;
              return;
            }
            str = Conversions.ToString(e.FormattedValue);
          }
          else
          {
            double num;
            try
            {
              num = Conversions.ToDouble(e.FormattedValue);
            }
            catch (Exception ex)
            {
              ProjectData.SetProjectError(ex);
              publicva.ToneValueValidatingDIS = true;
              ProjectData.ClearProjectError();
              return;
            }
            if (num > 254.1 | num < 63.0)
            {
              publicva.ToneValueValidatingDIS = true;
              return;
            }
            str = string.Format("{0:###.0}", (object) num);
          }
          if (!this.Column亚音编码.Items.Contains((object) str))
          {
            this.Column亚音编码.Items.Add((object) str);
            if (!this.Column亚音解码.Items.Contains((object) str))
              this.Column亚音解码.Items.Add((object) str);
          }
          if (this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音解码", 0].ColumnIndex)
            this.ChannelMsgDataGridView["Column亚音解码", rowIndex].Value = (object) str;
          if (this.ChannelMsgDataGridView.CurrentCell.ColumnIndex == this.ChannelMsgDataGridView["Column亚音编码", 0].ColumnIndex)
            this.ChannelMsgDataGridView["Column亚音编码", rowIndex].Value = (object) str;
        }
      }
    }

    private void ChannelMsgDataGridView_RowPostPaint(
      object sender,
      DataGridViewRowPostPaintEventArgs e)
    {
      string[] strArray = new string[4]
      {
        "A CALL",
        "B CALL",
        "A VFO",
        "B VFO"
      };
      Brush brush = (Brush) new SolidBrush(this.ChannelMsgDataGridView.RowHeadersDefaultCellStyle.ForeColor);
      Font font = new Font("Arial", 9f, FontStyle.Bold);
      if (e.RowIndex > 511)
      {
        if (e.RowIndex == 512)
          brush = Brushes.Red;
        else if (e.RowIndex == 513)
          brush = Brushes.Orange;
        else if (e.RowIndex == 514)
          brush = Brushes.Blue;
        else if (e.RowIndex == 515)
          brush = Brushes.Green;
        e.Graphics.DrawString(strArray[checked (e.RowIndex - 512)].ToString(), font, brush, (float) checked (e.RowBounds.Location.X + 2), (float) checked (e.RowBounds.Location.Y + 5));
      }
      else
        e.Graphics.DrawString(checked (e.RowIndex + 0).ToString(), this.ChannelMsgDataGridView.DefaultCellStyle.Font, brush, (float) e.RowBounds.Location.X + (float) checked (this.ChannelMsgDataGridView.RowHeadersWidth - (e.RowIndex + 0).ToString().Length * 8) / 2f, (float) checked (e.RowBounds.Location.Y + 5));
    }

    private void ChannelMsgDataGridView_CellMouseClick(
      object sender,
      DataGridViewCellMouseEventArgs e)
    {
      int columnIndex = this.ChannelMsgDataGridView["Column更多", 0].ColumnIndex;
      int rowIndex = this.ChannelMsgDataGridView.CurrentCell.RowIndex;
      if (columnIndex == this.ChannelMsgDataGridView.CurrentCell.ColumnIndex)
      {
        MyProject.Forms.ChannelEditForm.ChannelEditForm_Load(RuntimeHelpers.GetObjectValue(sender), (EventArgs) e);
        MyProject.Forms.MDIParent1.SafeLoadWindowByName((Form) MyProject.Forms.ChannelEditForm);
      }
      else
      {
        if (!Operators.ConditionalCompareObjectEqual((object) "", this.ChannelMsgDataGridView["ColumnRxFreq", rowIndex].Value, false))
          return;
        this.ChannelMsgDataGridView.CurrentCell = this.ChannelMsgDataGridView.Rows[rowIndex].Cells[0];
        this.ChannelMsgDataGridView.BeginEdit(true);
      }
    }

    private void Button信道编辑_Click(object sender, EventArgs e)
    {
      MyProject.Forms.ChannelEditForm.ChannelEditForm_Load(RuntimeHelpers.GetObjectValue(sender), e);
      MyProject.Forms.MDIParent1.SafeLoadWindowByName((Form) MyProject.Forms.ChannelEditForm);
    }

    public void GetStr_CHMsg(int i)
    {
      bool flag = false;
      int integer = Conversions.ToInteger(this.Get_CHAddress(i));
      if (i > 511)
      {
        if (Operators.ConditionalCompareObjectNotEqual((object) "", this.Get_RxFreqStr(integer, (int) publicva.EEPROM_Byte[checked (integer + 15)] & 15, (int) publicva.EEPROM_Byte[checked (integer + 11)] & ((int) publicva.Bit0 | (int) publicva.Bit1)), false))
          flag = true;
      }
      else if (this.CHStatus_Read(i, 8064) && Operators.ConditionalCompareObjectNotEqual((object) "", this.Get_RxFreqStr(integer, (int) publicva.EEPROM_Byte[checked (integer + 15)] & 15, (int) publicva.EEPROM_Byte[checked (integer + 11)] & ((int) publicva.Bit0 | (int) publicva.Bit1)), false))
        flag = true;
      if (flag)
      {
        this.ChannelMsgDataGridView["ColumnRxFreq", i].Value = RuntimeHelpers.GetObjectValue(this.Get_RxFreqStr(checked (integer + 0), (int) publicva.EEPROM_Byte[checked (integer + 15)] & 15, (int) publicva.EEPROM_Byte[checked (integer + 11)] & ((int) publicva.Bit0 | (int) publicva.Bit1)));
        this.ChannelMsgDataGridView["Column差频方向", i].Value = RuntimeHelpers.GetObjectValue(this.Column差频方向.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 14)] & ((uint) publicva.Bit2 | (uint) publicva.Bit3)) >> 2)]);
        this.ChannelMsgDataGridView["ColumnTxFreq", i].Value = RuntimeHelpers.GetObjectValue(this.Get_TxFreqStr(checked (integer + 3), (int) publicva.EEPROM_Byte[checked (integer + 15)] & 15, (int) publicva.EEPROM_Byte[checked (integer + 12)] & ((int) publicva.Bit0 | (int) publicva.Bit1)));
        this.ChannelMsgDataGridView["Column亚音解码类型", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码类型.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 7)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5)) >> 4)]);
        this.ChannelMsgDataGridView["Column亚音解码", i].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(checked (integer + 7)));
        this.ChannelMsgDataGridView["Column亚音编码类型", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码类型.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 9)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5)) >> 4)]);
        this.ChannelMsgDataGridView["Column亚音编码", i].Value = RuntimeHelpers.GetObjectValue(this.Get_CTC_DCS_Str(checked (integer + 9)));
        this.ChannelMsgDataGridView["Column发射功率", i].Value = RuntimeHelpers.GetObjectValue(this.Column发射功率.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 13)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5)) >> 4)]);
        this.ChannelMsgDataGridView["Column扫描添加", i].Value = i <= 511 ? (!this.CHStatus_Read(i, 8128) ? RuntimeHelpers.GetObjectValue(this.Column扫描添加.Items[1]) : RuntimeHelpers.GetObjectValue(this.Column扫描添加.Items[0])) : RuntimeHelpers.GetObjectValue(this.Column扫描添加.Items[1]);
        this.ChannelMsgDataGridView["Column带宽", i].Value = RuntimeHelpers.GetObjectValue(this.Column带宽.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 14)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5)) >> 4)]);
        this.ChannelMsgDataGridView["Column可选信令", i].Value = RuntimeHelpers.GetObjectValue(this.Column可选信令.Items[(int) (byte) (((uint) publicva.EEPROM_Byte[checked (integer + 12)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5 | (uint) publicva.Bit6)) >> 4)]);
      }
      else
        this.Clr_Channel(i);
    }

    public void SetData_CHMsg(int i)
    {
      bool flag = false;
      int integer = Conversions.ToInteger(this.Get_CHAddress(i));
      if (Operators.ConditionalCompareObjectNotEqual(this.ChannelMsgDataGridView["ColumnRxFreq", i].Value, (object) "", false) && Operators.ConditionalCompareObjectNotEqual((object) "", this.ChannelMsgDataGridView["ColumnTxFreq", i].Value, false))
        flag = true;
      if (flag)
      {
        publicva.EEPROM_Byte[checked (integer + 15)] = Conversions.ToByte(this.Get_FreqRangID(Conversions.ToDouble(this.ChannelMsgDataGridView["ColumnRxFreq", i].Value)));
        publicva.EEPROM_Byte[checked (integer + 11)] = Conversions.ToByte(Operators.OrObject((object) (byte) ((int) publicva.EEPROM_Byte[checked (integer + 11)] & (int) (byte) ~((int) publicva.Bit0 | (int) publicva.Bit1)), this.Get_FreqStepFlag(Conversions.ToDouble(this.ChannelMsgDataGridView["ColumnRxFreq", i].Value))));
        this.Set_FreqData(checked (integer + 0), Conversions.ToString(this.ChannelMsgDataGridView["ColumnRxFreq", i].Value));
        publicva.EEPROM_Byte[checked (integer + 14)] = checked ((byte) ((int) publicva.EEPROM_Byte[integer + 14] & (int) unchecked ((byte) ~((int) publicva.Bit2 | (int) publicva.Bit3)) | this.Column差频方向.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column差频方向", i].Value)) << 2));
        publicva.EEPROM_Byte[checked (integer + 12)] = Conversions.ToByte(Operators.OrObject((object) (byte) ((int) publicva.EEPROM_Byte[checked (integer + 12)] & (int) (byte) ~((int) publicva.Bit0 | (int) publicva.Bit1)), this.Get_FreqStepFlag(Conversions.ToDouble(this.ChannelMsgDataGridView["ColumnTxFreq", i].Value))));
        this.Set_FreqData(checked (integer + 3), Conversions.ToString(this.ChannelMsgDataGridView["ColumnTxFreq", i].Value));
        this.Set_CTC_DCS_Data(checked (integer + 7), Conversions.ToString(this.ChannelMsgDataGridView["Column亚音解码", i].Value), this.Column亚音解码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音解码类型", i].Value)));
        this.Set_CTC_DCS_Data(checked (integer + 9), Conversions.ToString(this.ChannelMsgDataGridView["Column亚音编码", i].Value), this.Column亚音编码类型.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column亚音编码类型", i].Value)));
        publicva.EEPROM_Byte[checked (integer + 13)] = checked ((byte) ((int) publicva.EEPROM_Byte[integer + 13] & (int) unchecked ((byte) ~((int) publicva.Bit4 | (int) publicva.Bit5)) | this.Column发射功率.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column发射功率", i].Value)) << 4));
        if (this.Column扫描添加.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column扫描添加", i].Value)) != 0)
        {
          if (i <= 511)
            this.CHStatusList_Write(i, "删除", 8128);
        }
        else if (i <= 511)
          this.CHStatusList_Write(i, "添加", 8128);
        publicva.EEPROM_Byte[checked (integer + 14)] = checked ((byte) ((int) publicva.EEPROM_Byte[integer + 14] & (int) unchecked ((byte) ~((int) publicva.Bit4 | (int) publicva.Bit5)) | this.Column带宽.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column带宽", i].Value)) << 4));
        publicva.EEPROM_Byte[checked (integer + 12)] = checked ((byte) ((int) publicva.EEPROM_Byte[integer + 12] & (int) unchecked ((byte) ~((int) publicva.Bit4 | (int) publicva.Bit5 | (int) publicva.Bit6)) | this.Column可选信令.Items.IndexOf(RuntimeHelpers.GetObjectValue(this.ChannelMsgDataGridView["Column可选信令", i].Value)) << 4));
        if (i > 511)
          return;
        this.CHStatusList_Write(i, "添加", 8064);
      }
      else
      {
        int num = 0;
        do
        {
          publicva.EEPROM_Byte[checked (integer + num)] = (byte) 0;
          checked { ++num; }
        }
        while (num <= 31);
        if (i <= 511)
        {
          this.CHStatusList_Write(i, "删除", 8064);
          this.CHStatusList_Write(i, "删除", 8128);
        }
      }
    }

    public object Get_CTC_DCS_Str(int Address)
    {
      int num = (int) (byte) (((uint) publicva.EEPROM_Byte[checked (Address + 0)] & ((uint) publicva.Bit4 | (uint) publicva.Bit5)) >> 4);
      string ctcDcsStr;
      if (num == 0)
      {
        ctcDcsStr = Conversions.ToString(this.Column亚音编码.Items[0]);
      }
      else
      {
        double a = (double) checked (((int) publicva.EEPROM_Byte[Address + 0] & 15) * 256 + (int) publicva.EEPROM_Byte[Address + 1]);
        if (num == 3)
        {
          int integer = Conversions.ToInteger(Conversion.Oct(checked ((long) Math.Round(a)) & 511L));
          ctcDcsStr = ((uint) publicva.EEPROM_Byte[checked (Address + 0)] & (uint) publicva.Bit7) <= 0U ? "D" + string.Format("{0:D3}", (object) integer) + "N" : "D" + string.Format("{0:D3}", (object) integer) + "I";
        }
        else
          ctcDcsStr = string.Format("{0:###.0}", (object) (a / 10.0));
      }
      if (!this.Column亚音编码.Items.Contains((object) ctcDcsStr))
      {
        this.Column亚音编码.Items.Add((object) ctcDcsStr);
        if (!this.Column亚音解码.Items.Contains((object) ctcDcsStr))
          this.Column亚音解码.Items.Add((object) ctcDcsStr);
      }
      return (object) ctcDcsStr;
    }

    public void Set_CTC_DCS_Data(int Address, string ToneStr, int ToneMode)
    {
      if (!this.Column亚音编码.Items.Contains((object) ToneStr))
      {
        this.Column亚音编码.Items.Add((object) ToneStr);
        if (!this.Column亚音解码.Items.Contains((object) ToneStr))
          this.Column亚音解码.Items.Add((object) ToneStr);
      }
      publicva.EEPROM_Byte[checked (Address + 0)] = checked ((byte) ((int) publicva.EEPROM_Byte[Address + 0] & (int) unchecked ((byte) ~((int) publicva.Bit4 | (int) publicva.Bit5)) | ToneMode << 4));
      switch (ToneMode)
      {
        case 0:
          publicva.EEPROM_Byte[checked (Address + 0)] = checked ((byte) ((int) publicva.EEPROM_Byte[Address + 0] & 240));
          publicva.EEPROM_Byte[checked (Address + 1)] = checked ((byte) ((int) publicva.EEPROM_Byte[Address + 1] & 0));
          break;
        case 3:
          double a1 = Conversions.ToDouble("&H" + Conversion.Hex((object) ("&O" + Conversions.ToString(Conversions.ToDouble(ToneStr.Substring(1, 3))))));
          publicva.EEPROM_Byte[checked (Address + 0)] = checked ((byte) ((long) ((int) publicva.EEPROM_Byte[Address + 0] & 240) | ((long) Math.Round(a1) & 3840L) >> 8));
          publicva.EEPROM_Byte[checked (Address + 1)] = checked ((byte) ((long) Math.Round(a1) & (long) byte.MaxValue));
          publicva.EEPROM_Byte[checked (Address + 0)] = Operators.CompareString("I", ToneStr.Substring(4, 1), false) != 0 ? (byte) ((int) publicva.EEPROM_Byte[checked (Address + 0)] & (int) ~publicva.Bit7) : (byte) ((int) publicva.EEPROM_Byte[checked (Address + 0)] | (int) publicva.Bit7);
          break;
        default:
          double num;
          try
          {
            num = Conversions.ToDouble(ToneStr);
          }
          catch (Exception ex)
          {
            ProjectData.SetProjectError(ex);
            num = 67.0;
            ProjectData.ClearProjectError();
          }
          double a2 = num * 10.0;
          publicva.EEPROM_Byte[checked (Address + 0)] = checked ((byte) ((long) ((int) publicva.EEPROM_Byte[Address + 0] & 240) | ((long) Math.Round(a2) & 3840L) >> 8));
          publicva.EEPROM_Byte[checked (Address + 1)] = checked ((byte) ((long) Math.Round(a2) & (long) byte.MaxValue));
          break;
      }
    }

    public object Get_RxFreqStr(int Address, int FreqRangID, int CHStepIndex)
    {
      double[] numArray = new double[3]
      {
        5000.0,
        6250.0,
        2500.0
      };
      double num1 = (double) checked ((int) publicva.EEPROM_Byte[Address + 0] * 65536) + (double) checked ((int) publicva.EEPROM_Byte[Address + 1] * 256) + (double) checked ((int) publicva.EEPROM_Byte[Address + 2] * 1);
      if (CHStepIndex > 2)
        CHStepIndex = 0;
      double num2 = (double) (checked ((long) Math.Round(unchecked (num1 * numArray[CHStepIndex]))) / 10L);
      return !((double) publicva.RxFreqRang[FreqRangID, 1] >= num2 & num2 >= (double) publicva.RxFreqRang[FreqRangID, 0]) ? (object) "" : (object) string.Format("{0:#00.00000}", (object) (num2 / 100000.0));
    }

    public object Get_TxFreqStr(int Address, int FreqRangID, int CHStepIndex)
    {
      double[] numArray = new double[3]
      {
        5000.0,
        6250.0,
        2500.0
      };
      double num = (double) (checked ((long) Math.Round(unchecked ((double) checked ((int) publicva.EEPROM_Byte[Address + 0] * 65536) + (double) checked ((int) publicva.EEPROM_Byte[Address + 1] * 256) + (double) checked ((int) publicva.EEPROM_Byte[Address + 2] * 1) * numArray[CHStepIndex]))) / 10L);
      return !((double) checked (publicva.RxFreqRang[FreqRangID, 1] - publicva.RxFreqRang[FreqRangID, 0]) >= num & num >= 0.0) ? (object) "" : (object) string.Format("{0:##0.00000}", (object) (num / 100000.0));
    }

    public void Set_FreqData(int Address, string FreqStr)
    {
      double[] numArray = new double[3]
      {
        5000.0,
        6250.0,
        2500.0
      };
      double Freq;
      try
      {
        Freq = Conversions.ToDouble(FreqStr);
      }
      catch (Exception ex)
      {
        ProjectData.SetProjectError(ex);
        Freq = 0.0;
        ProjectData.ClearProjectError();
      }
      int integer = Conversions.ToInteger(this.Get_FreqStepFlag(Freq));
      double a = (double) (checked ((long) Math.Round(unchecked (Freq * 1000000.0))) / checked ((long) Math.Round(numArray[integer])));
      publicva.EEPROM_Byte[checked (Address + 0)] = checked ((byte) (((long) Math.Round(a) & 16711680L) >> 16));
      publicva.EEPROM_Byte[checked (Address + 1)] = checked ((byte) (((long) Math.Round(a) & 65280L) >> 8));
      publicva.EEPROM_Byte[checked (Address + 2)] = checked ((byte) (((long) Math.Round(a) & (long) byte.MaxValue) >> 0));
    }

    public object Get_FreqStepFlag(double Freq)
    {
      uint num = checked ((uint) Math.Round(unchecked (Freq * 1000000.0)));
      if ((long) num % 5000L == 0L)
        return (object) 0;
      if ((long) num % 6250L == 0L)
        return (object) 1;
      return (long) num % 2500L == 0L ? (object) 2 : (object) 0;
    }

    public object Get_FreqRangID(double Freq)
    {
      byte[] numArray = new byte[7]
      {
        publicva.Bit0,
        publicva.Bit1,
        publicva.Bit2,
        publicva.Bit3,
        publicva.Bit4,
        publicva.Bit5,
        publicva.Bit6
      };
      uint num = checked ((uint) Math.Round(unchecked (Freq * 100000.0)));
      uint freqRangId = 0;
      while (!(publicva.RxFreqRang[checked ((int) freqRangId), 1] >= num & num >= publicva.RxFreqRang[checked ((int) freqRangId), 0]) || ((uint) publicva.EEPROM_Byte[12] & (uint) numArray[checked ((int) freqRangId)]) > 0U)
      {
        checked { ++freqRangId; }
        if (freqRangId > 6U)
          return (object) -1;
      }
      return (object) freqRangId;
    }

    public object JudgeInputRxFreq(string StrFreq, bool msg)
    {
      string str;
      try
      {
        double Freq = Conversions.ToDouble(StrFreq);
        if (Conversions.ToInteger(this.Get_FreqRangID(Freq)) != -1)
        {
          uint num1 = checked ((uint) Math.Round(unchecked (Freq * 1000000.0)));
          if ((long) num1 % 6250L != 0L && (long) num1 % 5000L != 0L && (long) num1 % 2500L != 0L)
          {
            int num2 = checked ((int) unchecked ((long) num1 / 5000L));
            if ((long) num1 % 5000L > 10000L)
              checked { ++num2; }
            num1 = checked ((uint) (num2 * 5000));
          }
          str = string.Format("{0:#00.00000}", (object) ((double) num1 / 1000000.0));
        }
        else
        {
          if (msg)
            this.Msgbox_Msg("频率超出范围", "frequency out of range,out of range");
          str = "";
        }
      }
      catch (Exception ex)
      {
        ProjectData.SetProjectError(ex);
        if (msg)
          this.Msgbox_Msg("频率超出范围", "frequency out of range,out of range");
        str = "";
        ProjectData.ClearProjectError();
      }
      return (object) str;
    }

    public object JudgeInputTxFreq(string RxFreq, string StrFreq, bool msg)
    {
      string str;
      try
      {
        double Freq = Conversions.ToDouble(RxFreq);
        double num1 = Conversions.ToDouble(StrFreq);
        int integer = Conversions.ToInteger(this.Get_FreqRangID(Freq));
        if (integer != -1)
        {
          uint num2 = checked (publicva.RxFreqRang[integer, 1] - publicva.RxFreqRang[integer, 0]);
          uint num3 = 0;
          uint num4 = checked ((uint) Math.Round(unchecked (num1 * 100000.0)));
          if (num2 >= num4 & num4 >= num3)
          {
            if ((long) num4 % 625L != 0L && (long) num4 % 500L != 0L && (long) num4 % 250L != 0L)
            {
              int num5 = checked ((int) unchecked ((long) num4 / 500L));
              if ((long) num4 % 500L > 1000L)
                checked { ++num5; }
              num4 = checked ((uint) (num5 * 500));
            }
            str = string.Format("{0:##0.00000}", (object) ((double) num4 / 100000.0));
          }
          else
          {
            if (msg)
              this.Msgbox_Msg("频率超出范围", "frequency out of range,out of range");
            str = "0.00000";
          }
        }
        else
        {
          if (msg)
            this.Msgbox_Msg("频率超出范围", "frequency out of range,out of range");
          str = "";
        }
      }
      catch (Exception ex)
      {
        ProjectData.SetProjectError(ex);
        if (msg)
          this.Msgbox_Msg("频率超出范围", "frequency out of range,out of range");
        str = "0.00000";
        ProjectData.ClearProjectError();
      }
      return (object) str;
    }

    public void Msgbox_Msg(string Zh_Msg, string En_Msg)
    {
      if (Operators.CompareString(publicva.Language, "zh-CN", false) == 0)
      {
        int num1 = (int) Interaction.MsgBox((object) Zh_Msg, MsgBoxStyle.Exclamation, (object) publicva.TypeName);
      }
      else
      {
        int num2 = (int) Interaction.MsgBox((object) En_Msg, MsgBoxStyle.Exclamation, (object) publicva.TypeName);
      }
    }

    public void CHStatusList_Write(int CHNo, string COM, int Address)
    {
      byte[] numArray = new byte[8]
      {
        (byte) 1,
        (byte) 2,
        (byte) 4,
        (byte) 8,
        (byte) 16,
        (byte) 32,
        (byte) 64,
        (byte) 128
      };
      checked { Address += CHNo >> 3; }
      if (Operators.CompareString(COM, "添加", false) == 0)
      {
        publicva.EEPROM_Byte[Address] = (byte) ((int) publicva.EEPROM_Byte[Address] & (int) ~numArray[CHNo & 7]);
      }
      else
      {
        if (Operators.CompareString(COM, "删除", false) != 0)
          return;
        publicva.EEPROM_Byte[Address] = (byte) ((int) publicva.EEPROM_Byte[Address] | (int) numArray[CHNo & 7]);
      }
    }

    public bool CHStatus_Read(int CHNo, int Address)
    {
      byte[] numArray = new byte[8]
      {
        (byte) 1,
        (byte) 2,
        (byte) 4,
        (byte) 8,
        (byte) 16,
        (byte) 32,
        (byte) 64,
        (byte) 128
      };
      checked { Address += CHNo >> 3; }
      return ((uint) publicva.EEPROM_Byte[Address] & (uint) numArray[CHNo & 7]) <= 0U;
    }

    public object Get_CHAddress(int i)
    {
      return (object) (i <= 511 ? checked (i * 32 + 8192) : checked ((i - 512) * 32 + 7936));
    }

    public void Clr_Channel(int i)
    {
      if (i > 511)
      {
        switch (i)
        {
          case 512:
            this.Init_Channel("146.00000", i);
            break;
          case 513:
            this.Init_Channel("440.00000", i);
            break;
          case 514:
            this.Init_Channel("146.00000", i);
            break;
          case 515:
            this.Init_Channel("440.00000", i);
            break;
        }
      }
      else
      {
        this.ChannelMsgDataGridView["ColumnRxFreq", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column差频方向", i].Value = (object) "";
        this.ChannelMsgDataGridView["ColumnTxFreq", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column亚音解码类型", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column亚音解码", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column亚音编码类型", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column亚音编码", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column发射功率", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column扫描添加", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column带宽", i].Value = (object) "";
        this.ChannelMsgDataGridView["Column可选信令", i].Value = (object) "";
      }
    }

    public void Init_Channel(string Freq, int i)
    {
      this.ChannelMsgDataGridView["ColumnRxFreq", i].Value = (object) Freq;
      this.ChannelMsgDataGridView["Column差频方向", i].Value = RuntimeHelpers.GetObjectValue(this.Column差频方向.Items[0]);
      this.ChannelMsgDataGridView["ColumnTxFreq", i].Value = Conversions.ToDouble(Freq) <= 300.0 ? (object) "0.60000" : (object) "5.00000";
      this.ChannelMsgDataGridView["Column亚音解码类型", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码类型.Items[0]);
      this.ChannelMsgDataGridView["Column亚音解码", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音解码.Items[0]);
      this.ChannelMsgDataGridView["Column亚音编码类型", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码类型.Items[0]);
      this.ChannelMsgDataGridView["Column亚音编码", i].Value = RuntimeHelpers.GetObjectValue(this.Column亚音编码.Items[0]);
      this.ChannelMsgDataGridView["Column发射功率", i].Value = RuntimeHelpers.GetObjectValue(this.Column发射功率.Items[0]);
      this.ChannelMsgDataGridView["Column扫描添加", i].Value = RuntimeHelpers.GetObjectValue(this.Column扫描添加.Items[0]);
      this.ChannelMsgDataGridView["Column带宽", i].Value = RuntimeHelpers.GetObjectValue(this.Column带宽.Items[0]);
      this.ChannelMsgDataGridView["Column可选信令", i].Value = RuntimeHelpers.GetObjectValue(this.Column可选信令.Items[0]);
      int integer = Conversions.ToInteger(this.Get_CHAddress(i));
      publicva.EEPROM_Byte[checked (integer + 6)] = (byte) 6;
      publicva.EEPROM_Byte[checked (integer + 9)] = (byte) ((int) publicva.EEPROM_Byte[checked (integer + 9)] | (int) publicva.Bit6);
      publicva.EEPROM_Byte[checked (integer + 11)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 12)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 13)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 14)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 15)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 16)] = (byte) 1;
      publicva.EEPROM_Byte[checked (integer + 17)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 18)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 19)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 20)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 21)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 22)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 23)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 24)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 25)] = (byte) 0;
      publicva.EEPROM_Byte[checked (integer + 26)] = (byte) 45;
      publicva.EEPROM_Byte[checked (integer + 27)] = (byte) 45;
      publicva.EEPROM_Byte[checked (integer + 28)] = (byte) 45;
      publicva.EEPROM_Byte[checked (integer + 29)] = (byte) 45;
      publicva.EEPROM_Byte[checked (integer + 30)] = (byte) 45;
      publicva.EEPROM_Byte[checked (integer + 31)] = (byte) 45;
    }

    private void Button1_Click(object sender, EventArgs e) => this.Close();
  }
}
