示例#1
0
 public SaveExecuteDialogViewModel(
     ViewModelEvents viewModelEvents,
     string buttonText,
     ETIC2Model etic2Model,
     SelectionItemType selectionItemType)
     : base(viewModelEvents, buttonText)
 {
     this.textInputViewModel = new TextInputViewModel(viewModelEvents, "Entry: ", string.Empty);
     this.etic2Model         = etic2Model;
     this.selectionItemType  = selectionItemType;
     this.viewModelEvents    = viewModelEvents;
 }
 public EditExecuteDialogViewModel(
     ViewModelEvents viewModelEvents,
     string buttonText,
     ETIC2Model etic2Model,
     SelectionItemType selectionItemType,
     string selectedItem)
     : base(viewModelEvents, buttonText)
 {
     this.SelectedItem = selectedItem;
     this.textInputViewModelSelectedItem = new TextInputViewModel(viewModelEvents, "Item name: ", selectedItem);
     this.etic2Model        = etic2Model;
     this.selectionItemType = selectionItemType;
     this.viewModelEvents   = viewModelEvents;
 }
 public DeleteExecuteDialogViewModel(
     ViewModelEvents viewModelEvents,
     string buttonText,
     ETIC2Model etic2Model,
     SelectionItemType selectionItemType,
     string selectedItem)
     : base(viewModelEvents, buttonText)
 {
     this.textInputViewModelSelectedItem            = new TextInputViewModel(viewModelEvents, "Item name: ", selectedItem);
     this.textInputViewModelSelectedItem.IsReadOnly = true;
     this.etic2Model            = etic2Model;
     this.selectionItemType     = selectionItemType;
     this.viewModelEvents       = viewModelEvents;
     this.resultDeleteOperation = string.Empty;
 }
        public DefinedSelectionInputListViewModel(
            ViewModelEvents viewModelEvents,
            string label,
            string selectedItem,
            SelectionItemType selectionItemType,
            ETIC2Model etic2Model,
            bool isContextMenuVisible)
            : base(viewModelEvents, label)
        {
            this.selectionItemType         = selectionItemType;
            this.etic2Model                = etic2Model;
            this.viewModelEvents           = viewModelEvents;
            this.isContextMenuVisible      = isContextMenuVisible;
            this.isDeleteItemButtonPressed = false;

            this.AddCommand    = new ActionCommand(this.OnAddCommand);
            this.EditCommand   = new ActionCommand(this.OnEditCommand);
            this.DeleteCommand = new ActionCommand(this.OnDeleteCommand);
        }