Selection.SelectOnly(EditingContext, ModelItem) 方法

定义

用于将一个项设置到选择集中的选择集帮助器方法。 任何现有项都被取消选择。

public:
 static System::Activities::Presentation::View::Selection ^ SelectOnly(System::Activities::Presentation::EditingContext ^ context, System::Activities::Presentation::Model::ModelItem ^ itemToSelect);
public static System.Activities.Presentation.View.Selection SelectOnly (System.Activities.Presentation.EditingContext context, System.Activities.Presentation.Model.ModelItem itemToSelect);
static member SelectOnly : System.Activities.Presentation.EditingContext * System.Activities.Presentation.Model.ModelItem -> System.Activities.Presentation.View.Selection
Public Shared Function SelectOnly (context As EditingContext, itemToSelect As ModelItem) As Selection

参数

context
EditingContext

要将此选择集应用到的编辑上下文。

itemToSelect
ModelItem

要选择的项。

返回

一个包含新选择的 Selection 对象。

适用于