本文整理汇总了C#中UITestControl.DrawHighlight方法的典型用法代码示例。如果您正苦于以下问题:C# UITestControl.DrawHighlight方法的具体用法?C# UITestControl.DrawHighlight怎么用?C# UITestControl.DrawHighlight使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UITestControl
的用法示例。
在下文中一共展示了UITestControl.DrawHighlight方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: PinPane
public void PinPane()
{
// Find the explorer main window
UITestControl anItem = this.UIBusinessDesignStudioWindow;
anItem.Find();
// Find the explorer sub window
UITestControl DocManager = new UITestControl(anItem);
DocManager.SearchProperties["AutomationId"] = "UI_DocManager_AutoID";
DocManager.Find();
// Find the left pane window
UITestControl DockLeft = new UITestControl(DocManager);
DockLeft.SearchProperties["AutomationId"] = "DockLeft";
DockLeft.Find();
// Find the tab page window
UITestControlCollection dockLeftChildren = DockLeft.GetChildren()[0].GetChildren();
//var TabPage = dockLeftChildren.FirstOrDefault(c => c.FriendlyName == "Explorer");
var TabPage = dockLeftChildren[0];
// Find the explorer sub window
UITestControl ExplorerPane = new UITestControl(TabPage);
ExplorerPane.SearchProperties["AutomationId"] = "UI_ExplorerPane_AutoID";
ExplorerPane.Find();
ExplorerPane.DrawHighlight();
// Find the pin
UITestControlCollection explorerChildren = ExplorerPane.GetChildren();
var unpinControl = explorerChildren.First(c => c.FriendlyName == "unpinBtn");
Mouse.Click(unpinControl);
}