private void BuildLight()
 {
     for (int x = 0; x < 8; x++)
     {
         for (int y = 0; y < 8; y++)
         {
             LPButton Button = SelectedPage.GetButton(x, y);
             Launchpad.setLED(x, y, Button.NormalColor);
         }
     }
 }
Beispiel #2
0
 public ButtonDialog(LPButton Button) : this()
 {
     ButtonConfig         = Button;
     Title                = String.Format("Configuring Button X: {0} / Y: {1}", Button.X, Button.Y);
     txtNormalColor.Text  = Button.NormalColor.ToString();
     txtPressedColor.Text = Button.PressedColor.ToString();
     txtCaption.Text      = Button.Caption;
     if (Button.Macro != null && Button.Macro.MacroType == LPMacroType.Sound)
     {
         var Macro = (LPSoundMacro)Button.Macro;
         txtSoundfile.Text     = Macro.Soundfile;
         chkLoopable.IsChecked = Macro.Loop;
     }
     else
     {
         ButtonConfig.Macro = new LPSoundMacro("");
     }
 }