示例#1
0
        protected override void RefreshView(ActionBase value)
        {
            ActionFetchText action = (ActionFetchText)value;

            arrayCombox.DataSource   = value.VariableModel.OfType <ActionVariable>().Select(c => c.Name).ToArray();
            arrayCombox.SelectedItem = action.ObjectName;
        }
示例#2
0
 private void SetPropertyName(ActionFetchText action)
 {
     if (attrCombox.Text == "Text" || attrCombox.Text == "Html")
     {
         action.PropertyName = attrCombox.Text;
     }
     else
     {
         action.PropertyName = propertyTextbox.Text;
     }
 }
示例#3
0
        private void ruleButton_Click(object sender, EventArgs e)
        {
            ActionFetchText action = (ActionFetchText)base.Action;

            SetPropertyName(action);
            StringRegexForm regex = new StringRegexForm(action.Pattern, action.GetDefaultValue());

            if (regex.ShowDialog() == System.Windows.Forms.DialogResult.OK)
            {
                action.Pattern = regex.Pattern;
            }
        }
示例#4
0
        void arrayCombox_SelectedIndexChanged(object sender, EventArgs e)
        {
            ActionFetchText action = (ActionFetchText)base.Action;

            if (arrayCombox.SelectedItem != null)
            {
                ActionVariable var1 = action.VariableModel.Find(arrayCombox.SelectedItem.ToString());
                methodComboBox1.Enabled = false;
                if (var1 is ActionTableVariable)
                {
                    methodComboBox1.Enabled = true;
                }
            }
        }