コード例 #1
0
        private bool SavePage_Appearance()
        {
            for (int i = 0; i < LstColumns.Items.Count; i++)
            {
                ListViewItem currItem    = LstColumns.Items[i];
                Int32        columnIndex = (Int32)currItem.Tag;

                if (currItem.Checked)
                {
                    ListViewEx.UnhideColumn(m_ListColumns[columnIndex]);
                }
                else
                {
                    ListViewEx.HideColumn(m_ListColumns[columnIndex]);
                }
            }

            m_Settings.Appearance.RedPrice   = ((double)TxtRedPrice.Value) / 100;
            m_Settings.Appearance.GreenPrice = ((double)TxtGreenPrice.Value) / 100;

            m_Settings.Appearance.OverrideAssetsColors = ChkOverrideColorsISK.Checked;
            m_Settings.Appearance.GreenIskLoss         = (double)TxtGreenIskLoss.Value;
            m_Settings.Appearance.RedIskLoss           = (double)TxtRedIskLoss.Value;

            return(true);
        }
コード例 #2
0
        private void LoadSettings_Columns()
        {
            foreach (Settings.V1._UIColumn currRow in m_Engine.m_Settings.UILocations.Columns)
            {
                Columns currColumnID = Columns_EnumFromString(currRow.Name);
                if (Columns.MaxColumns == currColumnID)
                {
                    continue;
                }

                ColumnHeader currColumn = LstRefinery.Columns[(int)currColumnID];
                currColumn.DisplayIndex = (Int32)currRow.Index;
                currColumn.Width        = (Int32)currRow.Width;

                if (currRow.Visible)
                {
                    ListViewEx.UnhideColumn(currColumn);
                }
                else
                {
                    ListViewEx.HideColumn(currColumn);
                }
            }
        }