]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/tuplet-iterator.cc
Imported Upstream version 2.16.0
[lilypond.git] / lily / tuplet-iterator.cc
index 97737db0f2b8582f19f24c6213119886d20a57b6..872ccae48d662215f64c844b5f4b9cadc920062c 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 1998--2011 Han-Wen Nienhuys <hanwen@xs4all.nl>,
+  Copyright (C) 1998--2012 Han-Wen Nienhuys <hanwen@xs4all.nl>,
                  Erik Sandberg <mandolaerik@gmail.com>
 
   LilyPond is free software: you can redistribute it and/or modify
@@ -63,8 +63,8 @@ Music *
 Tuplet_iterator::create_event (Direction d)
 {
   SCM ev_scm = scm_call_2 (ly_lily_module_constant ("make-span-event"),
-                          ly_symbol2scm ("TupletSpanEvent"),
-                          scm_from_int (d));
+                           ly_symbol2scm ("TupletSpanEvent"),
+                           scm_from_int (d));
 
   Music *mus = get_music ();
 
@@ -75,8 +75,8 @@ Tuplet_iterator::create_event (Direction d)
       ev->set_property ("numerator", mus->get_property ("numerator"));
       ev->set_property ("denominator", mus->get_property ("denominator"));
       ev->set_property ("tweaks", mus->get_property ("tweaks"));
-      ev->set_property ("length", spanner_duration_.smobbed_copy ()); 
-    }  
+      ev->set_property ("length", spanner_duration_.smobbed_copy ());
+    }
 
   synthesized_events_ = scm_cons (ev_scm, synthesized_events_);
   return ev;
@@ -104,23 +104,23 @@ Tuplet_iterator::process (Moment m)
       && m.main_part_ == next_split_mom_)
     {
       descend_to_bottom_context ();
-      if (tuplet_handler_.get_outlet ())
-       create_event (STOP)->send_to_context (tuplet_handler_.get_outlet ());
+      if (tuplet_handler_.get_context ())
+        create_event (STOP)->send_to_context (tuplet_handler_.get_context ());
 
       if (m.main_part_ < music_get_length ().main_part_)
-       {
-         tuplet_handler_.set_context (get_outlet ());
-         report_event (create_event (START));
+        {
+          tuplet_handler_.set_context (get_outlet ());
+          report_event (create_event (START));
 
-         next_split_mom_ += spanner_duration_;
-       }
+          next_split_mom_ += spanner_duration_;
+        }
       else
-       tuplet_handler_.set_context (0);
+        tuplet_handler_.set_context (0);
     }
   Music_wrapper_iterator::process (m);
   if (child_iter_ && child_iter_->ok ())
     descend_to_child (child_iter_->get_outlet ());
-  
+
 }
 
 void