以前可以在 Winforms ViewModels 中使用 ContentOverride。
这在 MDriven 7.0.0.11262 中仍然可行吗?
我不知道有任何变化,所以它应该像以前一样工作。ContentOverride 向渲染逻辑 (Eco.ViewModel.WinForms.ViewModelUserControl) 发出信号,以使用以下参数调用 OnColumnUIOverride 事件:
/// <summary>
/// Arguments for the OnColumnUIOverrideArgs event; fired to allow for override of column render.
/// If you have other UI components that you want to use in ViewModel driven UI's this event provides
/// a hook point to inject them.
/// </summary>
public class OnColumnUIOverrideArgs : EventArgs
{
public ViewModel ViewModel;
/// <summary>
/// The Column in question
/// </summary>
public ViewModelColumn ViewModelColumn;
/// <summary>
/// What kind of UI we had in mind
/// </summary>
public ViewModelUIComponentType ViewModelUIComponentType;
/// <summary>
/// Set this to false to stop us from calling default logic
/// </summary>
public bool ContinueWithDefault;
}