返回一个值,该值指示是否将来自 ItemContainerStyle 或 ItemContainerStyleSelector 属性的样式应用到指定项的容器元素。
命名空间: Microsoft.Windows.Controls.Ribbon
程序集: RibbonControlsLibrary(在 RibbonControlsLibrary.dll 中)
语法
声明
Protected Overrides Function ShouldApplyItemContainerStyle ( _
container As DependencyObject, _
item As Object _
) As Boolean
protected override bool ShouldApplyItemContainerStyle(
DependencyObject container,
Object item
)
protected:
virtual bool ShouldApplyItemContainerStyle(
DependencyObject^ container,
Object^ item
) override
abstract ShouldApplyItemContainerStyle :
container:DependencyObject *
item:Object -> bool
override ShouldApplyItemContainerStyle :
container:DependencyObject *
item:Object -> bool
protected override function ShouldApplyItemContainerStyle(
container : DependencyObject,
item : Object
) : boolean
参数
- container
类型:System.Windows.DependencyObject
容器元素。
- item
类型:System.Object
要显示的项。
返回值
类型:System.Boolean
如果 container 为 RibbonApplicationSplitMenuItem、RibbonSeparator 或 RibbonGallery,则为 false;否则为基实现返回的值。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。