当前位置: 首页>>代码示例>>C#>>正文


C# TreeViewItem.GetValue方法代码示例

本文整理汇总了C#中System.Windows.Controls.TreeViewItem.GetValue方法的典型用法代码示例。如果您正苦于以下问题:C# TreeViewItem.GetValue方法的具体用法?C# TreeViewItem.GetValue怎么用?C# TreeViewItem.GetValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.Windows.Controls.TreeViewItem的用法示例。


在下文中一共展示了TreeViewItem.GetValue方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetConnectingLineInfo

        /// <summary>
        /// Gets the value of the ConnectingLineInfo attached property for a
        /// specified TreeViewItem.
        /// </summary>
        /// <param name="element">
        /// The TreeViewItem from which the property value is read.
        /// </param>
        /// <returns>
        /// The ConnectingLineInfo property value for the TreeViewItem.
        /// </returns>
        internal static TreeViewItemConnectingLineInfo GetConnectingLineInfo(TreeViewItem element)
        {
            if (element == null)
            {
                throw new ArgumentNullException("element");
            }
            
            // Get the info and create on demand if necessary
            TreeViewItemConnectingLineInfo info = element.GetValue(ConnectingLineInfoProperty) as TreeViewItemConnectingLineInfo;
            if (info == null)
            {
                info = new TreeViewItemConnectingLineInfo(element);
                element.SetValue(ConnectingLineInfoProperty, info);
            }

            return info;
        }
开发者ID:modulexcite,项目名称:SilverlightToolkit,代码行数:27,代码来源:TreeViewConnectingLines.cs

示例2: GetIsBroughtIntoViewWhenSelected

 public static bool GetIsBroughtIntoViewWhenSelected(TreeViewItem treeViewItem)
 {
     return (bool)treeViewItem.GetValue(IsBroughtIntoViewWhenSelectedProperty);
 }
开发者ID:huyettoc,项目名称:duycm-workstation,代码行数:4,代码来源:TreeViewItemBehavior.cs

示例3: GetIsTreeViewItemDropOver

 public static bool GetIsTreeViewItemDropOver(TreeViewItem item)
 {
     return (bool)item.GetValue(IsTreeViewItemDropOverProperty);
 }
开发者ID:jango2015,项目名称:VS-Macros,代码行数:4,代码来源:MacrosControl.xaml.cs

示例4: GetIsItemSelected

 public static bool GetIsItemSelected(TreeViewItem element)
 {
     return (bool)element.GetValue(IsItemSelectedProperty);
 }
开发者ID:CADblokeWPFforks,项目名称:MultiSelectTreeView-1,代码行数:4,代码来源:MultiSelectTreeView.cs

示例5: GetBringSelectionIntoView

 public static bool GetBringSelectionIntoView(TreeViewItem treeViewItem)
 {
     return (bool)treeViewItem.GetValue(BringSelectionIntoViewProperty);
 }
开发者ID:mahanteshck,项目名称:antlrcs,代码行数:4,代码来源:TreeViewItemDisplay.cs

示例6: GetIsFiltered

 public static bool GetIsFiltered(TreeViewItem item)
 {
     return (bool)item.GetValue(IsFilteredProperty);
 }
开发者ID:kswoll,项目名称:restless,代码行数:4,代码来源:TreeViewItemFilter.cs

示例7: GetEnableContextMenuWorkaround

 public static bool GetEnableContextMenuWorkaround(TreeViewItem treeViewItem)
     => (bool) treeViewItem.GetValue(EnableContextMenuWorkaroundProperty);
开发者ID:SIXNetworks,项目名称:withSIX.Desktop,代码行数:2,代码来源:DataGridBehavior.cs

示例8: GetEnableFullRowSelection

 public static bool GetEnableFullRowSelection(TreeViewItem treeViewItem)
     => (bool) treeViewItem.GetValue(EnableFullRowSelectionProperty);
开发者ID:SIXNetworks,项目名称:withSIX.Desktop,代码行数:2,代码来源:DataGridBehavior.cs

示例9: GetBringIntoViewWhenSelected

 public static bool GetBringIntoViewWhenSelected(TreeViewItem treeViewItem)
 {
     return (bool)treeViewItem.GetValue(BringIntoViewWhenSelectedProperty);
 }
开发者ID:Reddds,项目名称:ProjectExplorer,代码行数:4,代码来源:TreeViewItemBehavior.cs

示例10: GetAssociatedToolbarItem

 /// <summary>
 /// Gets the value of the AssociatedToolbarItem attached property for a specified TreeViewItem.
 /// </summary>
 /// <param name="element">The TreeViewItem from which the property value is read.</param>
 /// <returns>The AssociatedToolbarItem property value for the TreeViewItem.</returns>
 internal static AddToolbarItem GetAssociatedToolbarItem(TreeViewItem element)
 {
     if (element == null)
     {
         throw new ArgumentNullException("element");
     }
     return element.GetValue(AssociatedToolbarItemProperty) as AddToolbarItem;
 }
开发者ID:Esri,项目名称:arcgis-viewer-silverlight,代码行数:13,代码来源:AddToolbarItem.cs

示例11: getParentConnectionForTreeViewItem

 private Connection getParentConnectionForTreeViewItem(TreeViewItem item)
 {
     if (item == null)
         return null;
     Resource resource = item.DataContext as Resource;
     if (resource != null)
     {
         Connection c = item.GetValue(TreeViewItemExtensions.ConnectionProperty) as Connection;
         if (c != null)
             return c;
     }
     Connection ds = item.DataContext as Connection;
     if (ds != null)
         return ds;
     TreeViewItem parent = item.Parent as TreeViewItem;
     if (parent == null)
         parent = ControlTreeHelper.FindAncestorOfType<TreeViewItem>(item);
     if (parent == null)
         return null;
     return getParentConnectionForTreeViewItem(parent);
 }
开发者ID:Esri,项目名称:arcgis-viewer-silverlight,代码行数:21,代码来源:BrowseContentDialog.cs


注:本文中的System.Windows.Controls.TreeViewItem.GetValue方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。