Ejemplo n.º 1
0
 static void pebble_MediaControlReceived(object sender, MediaControlReceivedEventArgs e)
 {
     Console.WriteLine("Received " + e.Command.ToString());
 }
Ejemplo n.º 2
0
 private void pebble_MediaControlReceived(object sender, MediaControlReceivedEventArgs e)
 {
     if (Properties.Settings.Default.PPTControl
         && Process.GetProcessesByName("POWERPNT").Count() > 0)
     {
         switch (e.Command)
         {
             case Pebble.MediaControls.Forward:
                 SendKeys.SendWait(" ");
                 break;
             case Pebble.MediaControls.Previous:
                 SendKeys.SendWait("{LEFT}");
                 break;
         }
     }
     else if (Properties.Settings.Default.MediaControl)
     {
         switch (e.Command)
         {
             case Pebble.MediaControls.PlayPause:
                 MediaControl.PlayPause();
                 break;
             case Pebble.MediaControls.Forward:
                 MediaControl.Next();
                 break;
             case Pebble.MediaControls.Previous:
                 MediaControl.Prev();
                 break;
         }
     }
 }