Skip to content

Commit

Permalink
Fixes #272 by using ParentBackstage.Background as ItemsPanelBackgroun…
Browse files Browse the repository at this point in the history
…d in Office 2013 theme
  • Loading branch information
batzen committed Feb 16, 2016
1 parent 0695c0c commit d636b13
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions Fluent.Ribbon.Showcase/ViewModels/ColorViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
namespace FluentTest.ViewModels
{
using System.Windows;
using System.Windows.Media;

public class ColorViewModel : ViewModel
Expand All @@ -14,7 +15,6 @@ public ColorViewModel()
{
this.StandardColor = Colors.Black;
this.HighlightColor = Colors.Yellow;
this.ThemeColor = Colors.Blue;
}

public Color StandardColor
Expand Down Expand Up @@ -44,10 +44,10 @@ public Color[] ThemeColors

public Color ThemeColor
{
get { return this.themeColor; }
get { return ((SolidColorBrush)Application.Current.Resources["RibbonThemeColorBrush"]).Color; }
set
{
this.themeColor = value;
Application.Current.Resources["RibbonThemeColorBrush"] = new SolidColorBrush(value);
this.OnPropertyChanged("ThemeColor");
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,6 @@
<Setter Property="Background"
Value="{Binding ParentBackstage.Background, RelativeSource={RelativeSource Self}, FallbackValue=Red}" />
<Setter Property="ItemsPanelBackground"
Value="{DynamicResource BackstagePanelBackgroundBrush}" />
Value="{Binding ParentBackstage.Background, RelativeSource={RelativeSource Self}, FallbackValue=Red}" />
</Style>
</ResourceDictionary>

0 comments on commit d636b13

Please sign in to comment.