Exemplo n.º 1
0
        public CreateTestWindow(InterceptedFunction func)
        {
            //
            // Required for Windows Form Designer support
            //
            InitializeComponent();

            //
            // TODO: Add any constructor code after InitializeComponent call
            //
            function             = func;
            firstMouseClickPoint = new Point();
            paramListView.Focus();
        }
Exemplo n.º 2
0
        private void functionNameComboBox_SelectedValueChanged(object sender, System.EventArgs e)
        {
            if (hasLoaded)
            {
                InterceptedFunctionDB db = InterceptedFunctionDB.GetInstance("functions.xml");
                InterceptedFunction   f  = db.GetFunctionByName(functionNameComboBox.SelectedItem.ToString());
                if (f != null)
                {
                    this.functionGroupLabel.Text = f.Category;
                    this.returnTypeLabel.Text    = f.ReturnType;

                    string modifier = null;
                    foreach (string s in f.Modifiers)
                    {
                        if (modifier != null)
                        {
                            modifier += ", ";
                        }

                        modifier += s;
                    }

                    this.modifiersLabel.Text = modifier;

                    // fill in the parameters
                    paramListView.Items.Clear();
                    foreach (InterceptedFunctionParameter param in f.Parameters)
                    {
                        ListViewItem item = new ListViewItem(param.Name);
                        item.SubItems.Add(param.Type);
                        param.TestValue = IgnoreParamString;
                        item.SubItems.Add(param.TestValue);

                        paramListView.Items.Add(item);
                    }
                }
                function = f;
            }
        }