internal FileEditorViewModel(PackageViewModel packageViewModel, IEditablePackageFile fileInEdit)
        {
            Debug.Assert(packageViewModel != null);
            Debug.Assert(fileInEdit != null);

            _packageViewModel = packageViewModel;
            _fileInEdit = fileInEdit;

            // Note: has to preserve the file name here so that the new file "appears" to be the same as old file
            _filePath = fileInEdit.OriginalPath ?? Path.Combine(FileHelper.GetTempFilePath(), fileInEdit.Name);

            _closeCommand = new RelayCommand<IFileEditorService>(CloseExecute);
            _saveCommand = new RelayCommand<IFileEditorService>(SaveExecute);
        }
        internal FileEditorViewModel(PackageViewModel packageViewModel, IEditablePackageFile fileInEdit)
        {
            Debug.Assert(packageViewModel != null);
            Debug.Assert(fileInEdit != null);

            _packageViewModel = packageViewModel;
            _fileInEdit       = fileInEdit;

            // Note: has to preserve the file name here so that the new file "appears" to be the same as old file
            _filePath = fileInEdit.OriginalPath ?? Path.Combine(FileHelper.GetTempFilePath(), fileInEdit.Name);

            _closeCommand = new RelayCommand <IFileEditorService>(CloseExecute);
            _saveCommand  = new RelayCommand <IFileEditorService>(SaveExecute);
        }