Skip to content

Commit

Permalink
Renaming GlassBorderThickness to GlassFrameThickness as part of #209
Browse files Browse the repository at this point in the history
  • Loading branch information
batzen committed Dec 13, 2015
1 parent 1f826d4 commit 665541c
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 21 deletions.
14 changes: 7 additions & 7 deletions Fluent/Controls/RibbonWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -78,17 +78,17 @@ public Thickness ResizeBorderThickness
/// <summary>
/// Gets or sets glass border thickness
/// </summary>
public Thickness GlassBorderThickness
public Thickness GlassFrameThickness
{
get { return (Thickness)this.GetValue(GlassBorderThicknessProperty); }
set { this.SetValue(GlassBorderThicknessProperty, value); }
get { return (Thickness)this.GetValue(GlassFrameThicknessProperty); }
set { this.SetValue(GlassFrameThicknessProperty, value); }
}

/// <summary>
/// Using a DependencyProperty as the backing store for GlassBorderThickness. This enables animation, styling, binding, etc...
/// Using a DependencyProperty as the backing store for GlassFrameThickness. This enables animation, styling, binding, etc...
/// </summary>
public static readonly DependencyProperty GlassBorderThicknessProperty =
DependencyProperty.Register("GlassBorderThickness", typeof(Thickness), typeof(RibbonWindow), new UIPropertyMetadata(new Thickness(0D), OnWindowChromeRelevantPropertyChanged));
public static readonly DependencyProperty GlassFrameThicknessProperty =
DependencyProperty.Register("GlassFrameThickness", typeof(Thickness), typeof(RibbonWindow), new UIPropertyMetadata(new Thickness(0D), OnWindowChromeRelevantPropertyChanged));

/// <summary>
/// Gets or sets corner radius
Expand Down Expand Up @@ -247,7 +247,7 @@ protected virtual void InitializeWindowChromeBehavior()
BindingOperations.SetBinding(behavior, WindowChromeBehavior.CaptionHeightProperty, new Binding { Path = new PropertyPath(RibbonProperties.TitleBarHeightProperty), Source = this });
BindingOperations.SetBinding(behavior, WindowChromeBehavior.ResizeBorderThicknessProperty, new Binding { Path = new PropertyPath(ResizeBorderThicknessProperty), Source = this });
BindingOperations.SetBinding(behavior, WindowChromeBehavior.CornerRadiusProperty, new Binding { Path = new PropertyPath(CornerRadiusProperty), Source = this });
BindingOperations.SetBinding(behavior, WindowChromeBehavior.GlassFrameThicknessProperty, new Binding { Path = new PropertyPath(GlassBorderThicknessProperty), Source = this });
BindingOperations.SetBinding(behavior, WindowChromeBehavior.GlassFrameThicknessProperty, new Binding { Path = new PropertyPath(GlassFrameThicknessProperty), Source = this });
BindingOperations.SetBinding(behavior, WindowChromeBehavior.UseAeroCaptionButtonsProperty, new Binding { Path = new PropertyPath(CanUseDwmProperty), Source = this });
Interaction.GetBehaviors(this).Add(behavior);
}
Expand Down
12 changes: 6 additions & 6 deletions Fluent/Themes/Office2010/RibbonWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@

<Grid x:Name="grid"
Background="{TemplateBinding Background}"
Margin="{TemplateBinding GlassBorderThickness}" />
Margin="{TemplateBinding GlassFrameThickness}" />

<StackPanel Background="Transparent"
x:Name="PART_IconImage"
Expand Down Expand Up @@ -690,7 +690,7 @@
TargetType="{x:Type Fluent:RibbonWindow}">
<Setter Property="OverridesDefaultStyle"
Value="True" />
<Setter Property="GlassBorderThickness">
<Setter Property="GlassFrameThickness">
<Setter.Value>
<MultiBinding Converter="{x:Static Converters:StaticConverters.ThicknessConverter}"
ConverterParameter="0">
Expand Down Expand Up @@ -720,7 +720,7 @@
<Condition Property="CanUseDwm"
Value="True" />
</MultiTrigger.Conditions>
<Setter Property="GlassBorderThickness">
<Setter Property="GlassFrameThickness">
<Setter.Value>
<MultiBinding Converter="{x:Static Converters:StaticConverters.ThicknessConverter}">
<Binding RelativeSource="{RelativeSource Self}"
Expand All @@ -741,15 +741,15 @@
<Condition Property="CanUseDwm"
Value="True" />
</MultiTrigger.Conditions>
<Setter Property="GlassBorderThickness"
<Setter Property="GlassFrameThickness"
Value="0,50,0,0" />
</MultiTrigger>
<Trigger Property="CanUseDwm"
Value="False">
<Setter Property="Template"
Value="{DynamicResource NonDwmRibbonWindowControlTemplate}" />
<!-- Cheat with GlassBorderThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassBorderThickness"
<!-- Cheat with GlassFrameThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassFrameThickness"
Value="0,0,0,1" />
</Trigger>
<Trigger Property="CanUseDwm"
Expand Down
4 changes: 2 additions & 2 deletions Fluent/Themes/Office2013/RibbonWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -280,8 +280,8 @@
Value="True" />
<Setter Property="BorderThickness"
Value="0" />
<!-- Cheat with GlassBorderThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassBorderThickness"
<!-- Cheat with GlassFrameThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassFrameThickness"
Value="0,0,0,1" />
<Setter Property="DontUseDwm"
Value="True" />
Expand Down
12 changes: 6 additions & 6 deletions Fluent/Themes/Windows8/RibbonWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@

<Grid x:Name="grid"
Background="{TemplateBinding Background}"
Margin="{TemplateBinding GlassBorderThickness}" />
Margin="{TemplateBinding GlassFrameThickness}" />

<StackPanel Background="Transparent"
x:Name="PART_IconImage"
Expand Down Expand Up @@ -647,7 +647,7 @@
TargetType="{x:Type Fluent:RibbonWindow}">
<Setter Property="OverridesDefaultStyle"
Value="True" />
<Setter Property="GlassBorderThickness">
<Setter Property="GlassFrameThickness">
<Setter.Value>
<MultiBinding Converter="{x:Static Converters:StaticConverters.ThicknessConverter}">
<Binding RelativeSource="{RelativeSource Self}"
Expand All @@ -672,7 +672,7 @@
<Condition Property="CanUseDwm"
Value="True" />
</MultiTrigger.Conditions>
<Setter Property="GlassBorderThickness">
<Setter Property="GlassFrameThickness">
<Setter.Value>
<MultiBinding Converter="{x:Static Converters:StaticConverters.ThicknessConverter}">
<Binding RelativeSource="{RelativeSource Self}"
Expand All @@ -693,15 +693,15 @@
<Condition Property="CanUseDwm"
Value="True" />
</MultiTrigger.Conditions>
<Setter Property="GlassBorderThickness"
<Setter Property="GlassFrameThickness"
Value="0,50,0,0" />
</MultiTrigger>
<Trigger Property="CanUseDwm"
Value="False">
<Setter Property="Template"
Value="{DynamicResource NonDwmRibbonWindowControlTemplate}" />
<!-- Cheat with GlassBorderThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassBorderThickness"
<!-- Cheat with GlassFrameThickness. We have to set something else than 0 to avoid some bugs in the WindowChrome class. -->
<Setter Property="GlassFrameThickness"
Value="0,0,0,1" />
</Trigger>
<Trigger Property="CanUseDwm"
Expand Down

0 comments on commit 665541c

Please sign in to comment.