Esempio n. 1
0
 public ProjectModuleView(ProjectModuleVM module)
 {
     InitializeComponent();
     this.module      = module;
     DataContext      = module;
     PwdBox.IsEnabled = !string.IsNullOrEmpty(PathBox.Text);
 }
 public ProjectModuleView(ProjectModuleVM module)
 {
     InitializeComponent();
     this.module = module;
     DataContext = module;
     PwdBox.IsEnabled = !string.IsNullOrEmpty(PathBox.Text);
 }
 public ProjectModuleView(ProjectModuleVM module)
 {
     InitializeComponent();
     this.module = module;
     DataContext = module;
 }
Esempio n. 4
0
 private void AddModule(string file)
 {
     if (!File.Exists(file)) {
         MessageBox.Show(string.Format("File '{0}' does not exists!", file), "ConfuserEx", MessageBoxButton.OK, MessageBoxImage.Error);
         return;
     }
     if (string.IsNullOrEmpty(App.Project.BaseDirectory)) {
         string directory = Path.GetDirectoryName(file);
         App.Project.BaseDirectory = directory;
         App.Project.OutputDirectory = Path.Combine(directory, "Confused");
     }
     var module = new ProjectModuleVM(App.Project, new ProjectModule());
     try {
         module.Path = Confuser.Core.Utils.GetRelativePath(file, App.Project.BaseDirectory);
     }
     catch {
         module.Path = file;
     }
     App.Project.Modules.Add(module);
 }