private void OnMetaDataChanged(MetaDataChanged msg) { if (msg.Key == "mode") { DoChangeEditorMode((EditorMode)msg.Value); } }
/// <summary> /// Method raising OnCopyMetaDataOnTable event if the click on the copy button of the table meta data control. /// </summary> private void onCopyMetaDataTableControl(object sender, EventArgs e) { MetaDataChanged?.Invoke(this, new EventArgs()); OnCopyMetaDataOnTable?.Invoke(this, new CopyMetaDataOnTableEventArgs { MetaData = _gridPresenter.GetMetaDataTable() }); }
/// <summary> /// Raises event 'MetaDataChanged' /// </summary> protected virtual void OnMetaDataChanged() { if (MetaDataChanged != null) { MetaDataChanged.Invoke(this, System.EventArgs.Empty); } }
protected override void Context() { _metaDataChanged = new MetaDataChanged { NewName = "NewName", OldName = "OldName", NewValue = "NewValue", OldValue = "OldValue" }; base.Context(); }
protected override void Context() { _metaDataChanged = new MetaDataChanged { NewName = "NewName", OldName = "OldName", NewValue = "NewValue", OldValue = "OldValue" }; base.Context(); _dataRepository.ExtendedProperties.Add(new ExtendedProperty <string> { Name = "OldName", Value = "OldValue" }); }
/// <summary> /// Method reacting on data validity changes of the meta data of the table. /// </summary> void metaDataControlOnIsDataValidChanged(object sender, EventArgs e) { var metaDataControl = sender as MetaDataEditControl; if (metaDataControl == null) { return; } metaDataControl.AcceptDataChanges(); MetaDataChanged?.Invoke(this, new EventArgs()); }
internal void SetMetaDataForTable(MetaDataTable metaData) { if (_metaDataControl == null) { return; } _gridPresenter.SetMetaDataForTable(metaData); MetaDataChanged?.Invoke(this, new EventArgs()); _metaDataControl.RefreshData(0); }
public ICommand ChangeMetaData(IEnumerable <DataRepository> observedData, MetaDataChanged metaDataChanged) { var macroCommand = new OSPSuiteMacroCommand <IOSPSuiteExecutionContext> { CommandType = Command.CommandTypeEdit, ObjectType = ObjectTypes.ObservedData, Description = Command.MetaDataModifiedInDataRepositories }; observedData.Each(x => macroCommand.Add(new ChangeObservedDataMetaDataCommand(x, metaDataChanged).Run(_executionContext))); return(macroCommand); }
private void onIsValidChangedColumnControlPanel(object sender, EventArgs e) { var control = sender as MetaDataEditControl; if (control == null) { return; } control.AcceptDataChanges(); MetaDataChanged?.Invoke(this, new EventArgs()); var column = control.Tag as ImportDataColumn; if (column == null) { return; } _gridPresenter.SetColumnImage(column.ColumnName); }