From a706aefd3dbf0552205dc0c850e2eba06bbf6e34 Mon Sep 17 00:00:00 2001 From: Victoria Plitt Date: Thu, 28 Mar 2019 18:06:45 +0200 Subject: Added "NewProjectDialog" dialog , styles and icons --- .../Dialogs/NewProjectDialog.xaml.cs | 30 +++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) (limited to 'Software/Visual_Studio/TEMP/Tango.Scripting/Tango.Scripting.IDE/Dialogs/NewProjectDialog.xaml.cs') diff --git a/Software/Visual_Studio/TEMP/Tango.Scripting/Tango.Scripting.IDE/Dialogs/NewProjectDialog.xaml.cs b/Software/Visual_Studio/TEMP/Tango.Scripting/Tango.Scripting.IDE/Dialogs/NewProjectDialog.xaml.cs index 376190e3a..f3e05e35f 100644 --- a/Software/Visual_Studio/TEMP/Tango.Scripting/Tango.Scripting.IDE/Dialogs/NewProjectDialog.xaml.cs +++ b/Software/Visual_Studio/TEMP/Tango.Scripting/Tango.Scripting.IDE/Dialogs/NewProjectDialog.xaml.cs @@ -1,4 +1,5 @@ -using System; + +using System; using System.Collections.Generic; using System.Linq; using System.Text; @@ -18,11 +19,34 @@ namespace Tango.Scripting.IDE.Dialogs /// /// Interaction logic for NewProjectDialog.xaml /// - public partial class NewProjectDialog : UserControl + public partial class NewProjectDialog : Window { - public NewProjectDialog() + static string _sAddNewProjectTitle = "Add New Project"; + static string _sNewProjectTitle = "New Project"; + protected bool _bNewProject; + + + public NewProjectDialog(bool bNewProject) { + _bNewProject = bNewProject; + InitializeComponent(); + Title = bNewProject ? _sAddNewProjectTitle : _sNewProjectTitle; + + } + private void CancelDialog(object sender, RoutedEventArgs e) + { + // Dialog box canceled + DialogResult = false; + } + + private void OKDialog(object sender, RoutedEventArgs e) + { + // Don't accept the dialog box if there is invalid data + // if (!IsValid(this)) return; + + // Dialog box accepted + DialogResult = true; } } } -- cgit v1.3.1