Exemplo n.º 1
0
        private void AddScreenReaderCommand(object sender, RoutedEventArgs e)
        {
            String fileExtention = ".grant";
            String fileNamePath  = guiFunctions.openFileDialog(fileExtention, "GRANT documents (.grant)|*.grant", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments));

            if (fileNamePath == null)
            {
                System.Windows.Forms.MessageBox.Show("The chosen screen reader doesn't exist!", "GRANT exception"); return;
            }
            ScreenReaderFunctions srf = new ScreenReaderFunctions(strategyMgr);

            srf.addScreenReader(@fileNamePath);
        }
Exemplo n.º 2
0
        private void LoadButton_Click(object sender, RoutedEventArgs e)
        {
            String fileName = guiFunctions.openFileDialog(".grant", "GRANT documents (.grant)|*.grant", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments));

            if (fileName == null)
            {
                System.Windows.Forms.MessageBox.Show("The chosen screen reader doesn't exist!", "GRANT exception"); return;
            }

            guiFunctions.loadGrantProject(fileName);
            Object tree = grantTrees.filteredTree;

            filteredTreeOutput.Items.Clear();
            root.Items.Clear();
            root.Header = "Filtered - Tree - Updated";
            guiFunctions.createTreeForOutput(tree, ref root); filteredTreeOutput.Items.Add(root);
            NodeButton.IsEnabled = false;
            updatePropertiesTable(strategyMgr.getSpecifiedTree().GetData(strategyMgr.getSpecifiedTree().Child(tree)).properties.IdGenerated);
            SaveButton.IsEnabled = true;
        }