예제 #1
0
        public FrmTester()
        {
            InitializeComponent();
            log = new TextBoxStreamWriter(txtConsole);

            modules = new Dictionary<string, ConnectionManager>();
            autoResponders = new List<AutoResponder>();
            prompters = new List<Prompter>();
            dataReceived = new ProducerConsumer<ReceivedPacket>(100);
            receivedResponses = new List<Response>();
            quickCommands = new List<QuickCommand>();

            ValidateAddModuleButton();
            ValidateAddAutoResponderButton();
            ValidateAddPrompterButton();
            ValidateStartPerformanceTest();
            ValidateAddQuickCommandButton();
            SelectModule(null);
            SelectResponder(null);
            SelectPrompter(null);
            SelectQuickCommand(null);

            dlgConsole = new StringEventHandler(Console);
            dlgMainThreadTask = new ThreadStart(MainThreadTask);
            dlgGetPromptDialog = new GetPromptDialogCaller(GetPromptDialog);
            dlgShowPromptDialog = new ShowPromptDialogCaller(ShowPromptDialog);

            stopwatch = new Stopwatch();
            mainThread = new Thread(dlgMainThreadTask);
            mainThread.IsBackground = true;
            mainThread.Start();
        }
예제 #2
0
        public FrmTester()
        {
            InitializeComponent();
            log = new TextBoxStreamWriter(txtConsole);

            modules           = new Dictionary <string, ConnectionManager>();
            autoResponders    = new List <AutoResponder>();
            prompters         = new List <Prompter>();
            dataReceived      = new ProducerConsumer <ReceivedPacket>(100);
            receivedResponses = new List <Response>();
            quickCommands     = new List <QuickCommand>();

            ValidateAddModuleButton();
            ValidateAddAutoResponderButton();
            ValidateAddPrompterButton();
            ValidateStartPerformanceTest();
            ValidateAddQuickCommandButton();
            SelectModule(null);
            SelectResponder(null);
            SelectPrompter(null);
            SelectQuickCommand(null);

            dlgConsole          = new StringEventHandler(Console);
            dlgMainThreadTask   = new ThreadStart(MainThreadTask);
            dlgGetPromptDialog  = new GetPromptDialogCaller(GetPromptDialog);
            dlgShowPromptDialog = new ShowPromptDialogCaller(ShowPromptDialog);

            stopwatch  = new Stopwatch();
            mainThread = new Thread(dlgMainThreadTask);
            mainThread.IsBackground = true;
            mainThread.Start();
        }