IDynamicEditorControl.cs 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. using System.Collections.Generic;
  2. using System.Configuration;
  3. using System.Windows;
  4. using System.Windows.Media;
  5. using InABox.Core;
  6. namespace InABox.DynamicGrid
  7. {
  8. public delegate void EditorControlValueChangedHandler(IDynamicEditorControl sender, Dictionary<string, object?> values);
  9. public interface IDynamicEditorControl
  10. {
  11. string ColumnName { get; set; }
  12. bool Loaded { get; set; }
  13. bool Changed { get; set; }
  14. IBaseEditor EditorDefinition { get; set; }
  15. bool IsEnabled { get; set; }
  16. void SetFocus();
  17. int DesiredHeight();
  18. event EditorControlValueChangedHandler OnEditorValueChanged;
  19. void Configure();
  20. void SetEnabled(bool enabled);
  21. void SetVisible(bool enabled);
  22. void SetValue(string property, object? value);
  23. object? GetValue(string property);
  24. IDynamicEditorHost Host { get; set; }
  25. }
  26. public interface IDynamicEditorControl<T> : IDynamicEditorControl
  27. {
  28. public T Value { get; set; }
  29. }
  30. }