src/FingersDance.Control.Player/UserControlPlayer.xaml.cs
changeset 163 d5148710e229
parent 162 0b9f989bcb37
child 165 e78e40b9d761
--- a/src/FingersDance.Control.Player/UserControlPlayer.xaml.cs	Fri Oct 16 21:06:25 2009 +0200
+++ b/src/FingersDance.Control.Player/UserControlPlayer.xaml.cs	Fri Oct 16 21:37:16 2009 +0200
@@ -260,12 +260,26 @@
         //This function Sets a brush in a specific rectangle of the StackPanelAnnotation
         public void displayStackPanelAnnotations(int id, Brush brushAnnotation)
         {
+            Object o = null;
             switch (id)
             {
-                case 1: rect1.Fill = brushAnnotation; break;
-                case 2: rect2.Fill = brushAnnotation; break;
-                case 3: rect3.Fill = brushAnnotation; break;
-                case 4: rect4.Fill = brushAnnotation; break;
+                case 1: 
+                    rect1.Fill = brushAnnotation;
+                    o = rect1.FindResource("Rect1Annotation");
+                    rect1.BeginStoryboard((Storyboard)o);
+                    break;
+                case 2: rect2.Fill = brushAnnotation;
+                    o = rect2.FindResource("Rect2Annotation");
+                    rect2.BeginStoryboard((Storyboard)o);
+                    break;
+                case 3: rect3.Fill = brushAnnotation;
+                    o = rect3.FindResource("Rect3Annotation");
+                    rect3.BeginStoryboard((Storyboard)o);
+                    break;
+                case 4: rect4.Fill = brushAnnotation;
+                    o = rect4.FindResource("Rect4Annotation");
+                    rect4.BeginStoryboard((Storyboard)o);
+                    break;
                 default: break;
             }
         }