diff options
author | Paul DiPietro <pauldipietro@users.noreply.github.com> | 2016-12-19 06:45:15 -0600 |
---|---|---|
committer | Rui Marinho <me@ruimarinho.net> | 2016-12-19 12:45:15 +0000 |
commit | df67dff982d45e6fb8d69b549b8683ca26f2a202 (patch) | |
tree | cf911d43a319cb2df65d39c12ef2bcc9c18a8d15 /Xamarin.Forms.Platform.WinRT/Platform.cs | |
parent | e0165abbcd1329a3dfd353548f5d75eef0c792de (diff) | |
download | xamarin-forms-df67dff982d45e6fb8d69b549b8683ca26f2a202.tar.gz xamarin-forms-df67dff982d45e6fb8d69b549b8683ca26f2a202.tar.bz2 xamarin-forms-df67dff982d45e6fb8d69b549b8683ca26f2a202.zip |
[UWP] Use toolbar foreground color on primary items (#640)
Diffstat (limited to 'Xamarin.Forms.Platform.WinRT/Platform.cs')
-rw-r--r-- | Xamarin.Forms.Platform.WinRT/Platform.cs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Xamarin.Forms.Platform.WinRT/Platform.cs b/Xamarin.Forms.Platform.WinRT/Platform.cs index e9f6b95c..2e30ac10 100644 --- a/Xamarin.Forms.Platform.WinRT/Platform.cs +++ b/Xamarin.Forms.Platform.WinRT/Platform.cs @@ -296,13 +296,16 @@ namespace Xamarin.Forms.Platform.WinRT button.Command = new MenuItemCommand(item); button.DataContext = item; -#if WINDOWS_UWP - toolBarProvider?.BindForegroundColor(button); -#endif ToolbarItemOrder order = item.Order == ToolbarItemOrder.Default ? ToolbarItemOrder.Primary : item.Order; + if (order == ToolbarItemOrder.Primary) + { +#if WINDOWS_UWP + toolBarProvider?.BindForegroundColor(button); +#endif commandBar.PrimaryCommands.Add(button); + } else commandBar.SecondaryCommands.Add(button); } |