示例#1
0
        private void runButton_Click(object sender, RoutedEventArgs e)
        {
            var _seed       = seedTB.Text;
            var _polynomial = polynomialTB.Text;
            var _fileName   = fileTB.Text;
            int _mode       = 0;

            if (encrypt.IsChecked == true)
            {
                _mode = 0;
            }
            if (decrypt.IsChecked == true)
            {
                _mode = 1;
            }

            _cipher.Init(_seed, _polynomial);
            var result = _cipher.GetOutput(_fileName, _mode);

            outputTB.Text = result;
        }