Пример #1
0
        public void SetUserSettings(UserSettings settings)
        {
            _settings = settings;

            tempFillList         = _settings.fillList;
            tempIgnoreBounds     = _settings.ignoreBounds;
            tempFilters          = _settings.filtersToShow;
            tempColumns          = _settings.columnsToShow;
            tempRiddleDifficulty = _settings.riddleDifficulty;
            tempGotLeaveEnding   = _settings.gotLeaveEnding;
            tempGotMariaEnding   = _settings.gotMariaEnding;
            tempGotWaterEnding   = _settings.gotWaterEnding;
            tempFrameLower       = _settings.lowerFrameBound;
            tempFrameHigher      = _settings.higherFrameBound;

            cb_fillListNoFilter.Checked          = _settings.fillList;
            cb_ignoreBoundsWhenSearching.Checked = _settings.ignoreBounds;
            txt_lowerFrameBound.Text             = _settings.lowerFrameBound.ToString();
            txt_higherFrameBound.Text            = _settings.higherFrameBound.ToString();
            cmb_riddleSetting.SelectedIndex      = (int)_settings.riddleDifficulty;
            cb_gotLeaveEnding.Checked            = _settings.gotLeaveEnding;
            cb_gotMariaEnding.Checked            = _settings.gotMariaEnding;
            cb_gotWaterEnding.Checked            = _settings.gotWaterEnding;

            for (int i = 0, len = cbl_filters.Items.Count; i < len; i++)
            {
                RNGColumns f = (RNGColumns)Enum.Parse(typeof(RNGColumns), cbl_filters.Items[i].ToString());
                RNGColumns c = (RNGColumns)Enum.Parse(typeof(RNGColumns), cbl_columns.Items[i].ToString());

                cbl_filters.SetItemChecked(i, (_settings.filtersToShow & f) != 0);
                cbl_columns.SetItemChecked(i, (_settings.columnsToShow & c) != 0);
            }
        }
Пример #2
0
        private void Cmb_riddleSetting_SelectedIndexChanged(object sender, EventArgs e)
        {
            ComboBox cb = sender as ComboBox;

            tempRiddleDifficulty = (RiddleDifficulty)cb.SelectedIndex;
        }