Skip to content

Commit

Permalink
Fix manager instance creation before setting properties
Browse files Browse the repository at this point in the history
  • Loading branch information
leocb committed Dec 23, 2019
1 parent 17070d5 commit 06a7811
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions MaterialSkinExample/MainForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@ public MainForm()

InitializeComponent();

// Initialize MaterialSkinManager
materialSkinManager = MaterialSkinManager.Instance;

// Set this to false to disable backcolor enforcing on non-materialSkin components
// This HAS to be set before the AddFormToManage()
materialSkinManager.EnforceBackcolorOnAllComponents = true;

// Initialize MaterialSkinManager
materialSkinManager = MaterialSkinManager.Instance;
// MaterialSkinManager properties
materialSkinManager.AddFormToManage(this);
materialSkinManager.Theme = MaterialSkinManager.Themes.LIGHT;
materialSkinManager.ColorScheme = new ColorScheme(Primary.Indigo500, Primary.Indigo700, Primary.Indigo100, Accent.Pink200, TextShade.WHITE);
Expand Down

0 comments on commit 06a7811

Please sign in to comment.