Ejemplo n.º 1
0
        public override void ButtonClicked()
        {
            LevelEditDialog dialog = new LevelEditDialog(_textBox.Text, 30, false, false, false);

            dialog.Owner = WpfUtilities.FindParentControl <Window>(_button);

            if (dialog.ShowDialog() == true)
            {
                _textBox.Text = dialog.Text;
            }
        }
Ejemplo n.º 2
0
        public override void ButtonClicked()
        {
            var    db     = _tab.GetTable <int>(ServerDbs.Skills);
            object maxVal = 20;
            var    tuple  = db.TryGetTuple(((ReadableTuple <TKey>)_tab.List.SelectedItem).GetKey <int>());

            if (tuple != null)
            {
                maxVal = tuple.GetValue(ServerSkillAttributes.MaxLevel);
            }

            LevelEditDialog dialog = new LevelEditDialog(_textBox.Text, maxVal, false);

            dialog.Owner = WpfUtilities.FindParentControl <Window>(_button);

            if (dialog.ShowDialog() == true)
            {
                _textBox.Text = dialog.Text;
            }
        }