Exemplo n.º 1
0
        protected void SetUp()
        {
	        Common.Testing = true;
            _configTool = new ConfigurationTool();

            string testPath = PathPart.Bin(Environment.CurrentDirectory, "/ConfigurationTool/TestFiles");
            _inputBasePath = Common.PathCombine(testPath, "input");
            _expectBasePath = Common.PathCombine(testPath, "Expected");
            _outputBasePath = Common.PathCombine(testPath, "Output");
            const bool recursiveDelete = true;
            if (Directory.Exists(_outputBasePath))
            {
                DirectoryInfo di = new DirectoryInfo(_outputBasePath);
                Common.CleanDirectory(di);
            }
            Directory.CreateDirectory(_outputBasePath);

            _supportSource = Common.DirectoryPathReplace(testPath + "/../../../../DistFiles");

            string fileName = "DictionaryStyleSettings.xml";
            CopyFilesSupportToIO(fileName);

            fileName = "ScriptureStyleSettings.xml";
            CopyFilesSupportToIO(fileName);

            fileName = "StyleSettings.xml";
            CopyFilesSupportToIO(fileName);

            fileName = "StyleSettings.xsd";
            CopyFilesSupportToIO(fileName);

            string folderName = "Styles";
            CopyFolderSupportToIO(folderName);
            LoadParam();
        }
Exemplo n.º 2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            Param.SetValue(Param.LayoutSelected, grid.SelectedRows[0].Cells[0].Value.ToString());
            Param.DefaultValue[Param.LayoutSelected] = grid.SelectedRows[0].Cells[0].Value.ToString();
            Param.Write();
            ConfigurationTool configurationTool = new ConfigurationTool();

            configurationTool.InputType     = InputType;
            configurationTool.MediaType     = grid.SelectedRows[0].Cells[4].Value.ToString();
            configurationTool.Style         = grid.SelectedRows[0].Cells[0].Value.ToString().Replace(' ', '&');
            configurationTool.StartPosition = FormStartPosition.CenterScreen;
            configurationTool.IsExportOptionFromFlexOrParatext = true;
            configurationTool.ShowDialog();

            SelectedStyle = configurationTool.Style;

            Param.LoadSettings();
            LoadGridValues(sender);
        }
Exemplo n.º 3
0
        protected void SetUp()
        {
            cTool = new ConfigurationTool();
            cTool._fromNunit = true;
            cToolBL = new ConfigurationToolBL();

            //_pathwayPath = Common.PathCombine(Common.GetAllUserAppPath(), "SIL/Pathway");
            _pathwayPath = Common.GetAllUserPath();

            stylename = new ArrayList
                            {
                                "OneColumn",
                                "TwoColumn",
                                "LikeBuangPNG",
                                "FieldWorksStyles",
                                "FieldWorksArabicBased",
                                "Draft"
                            };

            string folderName = "Styles";
            CopyFolderSupportToIO(folderName);
        }
Exemplo n.º 4
0
		private void btnEdit_Click(object sender, EventArgs e)
		{
			Param.SetValue(Param.LayoutSelected, grid.SelectedRows[0].Cells[0].Value.ToString());
			Param.DefaultValue[Param.LayoutSelected] = grid.SelectedRows[0].Cells[0].Value.ToString();
			Param.Write();
			ConfigurationTool configurationTool = new ConfigurationTool();
			configurationTool.InputType = InputType;
			configurationTool.MediaType = grid.SelectedRows[0].Cells[4].Value.ToString();
			configurationTool.Style = grid.SelectedRows[0].Cells[0].Value.ToString().Replace(' ', '&');
			configurationTool.StartPosition = FormStartPosition.CenterScreen;
			configurationTool.ShowDialog();

			SelectedStyle = configurationTool.Style;

			Param.LoadSettings();
			LoadGridValues(sender);
		}
Exemplo n.º 5
0
		public void SetClassReference(ConfigurationTool configTool)
		{
			cTool = configTool;
		}