vb System.Windows.Automation.Provider.IRawElementProviderFragmentRoot.GetFocus类(方法)实例源码

下面列出了vb System.Windows.Automation.Provider.IRawElementProviderFragmentRoot.GetFocus 类(方法)源码代码实例,从而了解它的用法。

作者:VB.NET开发    项目:System.Windows.Automation.Provide   
''' <summary>
''' Returns the child element that is selected when the list gets focus.
''' </summary>
''' <returns>The selected item.</returns>
''' <remarks>
''' SelectedIndex is a class property that maintains the index of the currently
''' selected item in the myItems collection.</remarks>
Function GetFocus() As IRawElementProviderFragment _
    Implements IRawElementProviderFragmentRoot.GetFocus

    If SelectedIndex >= 0 Then
        Return DirectCast(myItems(SelectedIndex), IRawElementProviderFragment)
    Else
        Return Nothing
    End If
End Function 'IRawElementProviderFragmentRoot.GetFocus


问题


面经


文章

微信
公众号

扫码关注公众号