本文整理汇总了C#中Skin.Apply方法的典型用法代码示例。如果您正苦于以下问题:C# Skin.Apply方法的具体用法?C# Skin.Apply怎么用?C# Skin.Apply使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Skin
的用法示例。
在下文中一共展示了Skin.Apply方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ApplySkin
public void ApplySkin(Skin skin)
{
// Apply to children first so they don't override parent's properties
foreach (UIComponent control in this.controls)
control.ApplySkin(skin);
skin.Apply(this);
}
示例2: ApplySkin
/// <summary>
/// This applies a skin to this gui. If applyDefaults is true, then the
/// defaults for subsequent controls are also changed.
/// </summary>
/// <param name="skin">The skin to apply.</param>
/// <param name="applyDefaults">Should control defaults be modified?</param>
/// <param name="applyCurrent">Should existing controls have their properties modified?</param>
public void ApplySkin(Skin skin, bool applyCurrent, bool applyDefaults)
{
// Apply to GUI and possibly control defaults
skin.Apply(this, applyDefaults);
// Apply to every control already part of the GUI
if (applyCurrent)
{
foreach (UIComponent control in this.controls)
control.ApplySkin(skin);
}
}