Пример #1
0
        /// <summary>
        /// Handles functionality for the New Project button
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void BtnNewPrj_Click(object sender, EventArgs e)
        {
            //instantiate new project
            Project newProject = new Project();

            //create a new form and display
            NewForms.ProjectForm newForm = new NewForms.ProjectForm(newProject, true);
            newForm.ShowDialog();

            //update the project display panel
            WriteProjectLoadDisplay();

            //create the menu and display
            ProjectMenu.ProjectMenu menu = new ProjectMenu.ProjectMenu(newProject);
            menu.ShowDialog();
        }
Пример #2
0
        /// <summary>
        /// Handles functionality for the Load Project button
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void BtnLoadPrj_Click(object sender, EventArgs e)
        {
            //declare variables
            string  projectName;
            string  filepath = "";
            Project prj      = new Project();

            //get selected project name
            projectName = listBoxPrjs.SelectedItem.ToString();

            //navigate to the filepath
            filepath = Novelis.Filepath + projectName;

            //fill project data
            prj.SetTitle(projectName);
            Project.GetCoverXML(filepath, prj);

            //display the menu
            ProjectMenu.ProjectMenu menu = new ProjectMenu.ProjectMenu(prj);
            menu.ShowDialog();
        }