Exemple #1
0
 // Token: 0x06000034 RID: 52 RVA: 0x000044F0 File Offset: 0x000026F0
 public void EditColumn()
 {
     foreach (object obj in this.ListView.SelectedIndices)
     {
         int           index         = (int)obj;
         ColumnElement columnElement = this.Config.Columns.ColumnList[index];
         DebugTools.Print("Open dialog box: Edit overlay column (DialogBoxOverlayColumn)");
         using (DialogBoxOverlayColumn dialogBoxOverlayColumn = new DialogBoxOverlayColumn())
         {
             dialogBoxOverlayColumn.Text = "Edit Column";
             dialogBoxOverlayColumn.CheckboxColumnEnabled.Checked      = columnElement.Enabled;
             dialogBoxOverlayColumn.NumericUpDownColumnWidth.Value     = columnElement.Width;
             dialogBoxOverlayColumn.ComboBoxColumnData.SelectedIndex   = (int)columnElement.Data;
             dialogBoxOverlayColumn.CheckBoxShowHeader.Checked         = columnElement.ShowHeader;
             dialogBoxOverlayColumn.LabelHeaderColourPreview.BackColor = columnElement.HeaderColour;
             dialogBoxOverlayColumn.LabelDataColourPreview.BackColor   = columnElement.DataColour;
             dialogBoxOverlayColumn.ButtonColumnConfirm.Text           = "Confirm";
             if (dialogBoxOverlayColumn.ShowDialog() == DialogResult.OK)
             {
                 DebugTools.Print("Option change: Edit overlay column");
                 columnElement.Enabled      = dialogBoxOverlayColumn.CheckboxColumnEnabled.Checked;
                 columnElement.Width        = (int)dialogBoxOverlayColumn.NumericUpDownColumnWidth.Value;
                 columnElement.Data         = (DataSourceEnum)dialogBoxOverlayColumn.ComboBoxColumnData.SelectedIndex;
                 columnElement.ShowHeader   = dialogBoxOverlayColumn.CheckBoxShowHeader.Checked;
                 columnElement.HeaderColour = dialogBoxOverlayColumn.LabelHeaderColourPreview.BackColor;
                 columnElement.DataColour   = dialogBoxOverlayColumn.LabelDataColourPreview.BackColor;
                 GameMemory.OverlayUpdateConfig();
                 this.UpdateStatic();
             }
         }
     }
 }
Exemple #2
0
 // Token: 0x06000033 RID: 51 RVA: 0x00004400 File Offset: 0x00002600
 public void AddColumn()
 {
     using (DialogBoxOverlayColumn dialogBoxOverlayColumn = new DialogBoxOverlayColumn())
     {
         DebugTools.Print("Open dialog box: Add overlay column (DialogBoxOverlayColumn)");
         dialogBoxOverlayColumn.Text = "Add Column";
         dialogBoxOverlayColumn.ButtonColumnConfirm.Text = "Add";
         if (dialogBoxOverlayColumn.ShowDialog() == DialogResult.OK)
         {
             DebugTools.Print("Option change: Add overlay column");
             this.Config.Columns.ColumnList.Add(new ColumnElement
             {
                 Enabled      = true,
                 Data         = (DataSourceEnum)dialogBoxOverlayColumn.ComboBoxColumnData.SelectedIndex,
                 Width        = Convert.ToInt32(dialogBoxOverlayColumn.NumericUpDownColumnWidth.Value),
                 ShowHeader   = dialogBoxOverlayColumn.CheckBoxShowHeader.Checked,
                 HeaderColour = dialogBoxOverlayColumn.LabelHeaderColourPreview.BackColor,
                 DataColour   = dialogBoxOverlayColumn.LabelDataColourPreview.BackColor
             });
             GameMemory.OverlayUpdateConfig();
             this.UpdateStatic();
         }
     }
 }