]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/performer.cc
release: 0.0.77.jcn1
[lilypond.git] / lily / performer.cc
index 76b93332533521bb2c1f8ee82c3a0cacfb36f7ab..e26f2ef2da57f5ccc52da1b62d3e4df0c6249440 100644 (file)
@@ -9,12 +9,13 @@
 #include "performer-group-performer.hh"
 #include "debug.hh"
 
-IMPLEMENT_STATIC_NAME(Performer);
+
 IMPLEMENT_IS_TYPE_B(Performer);
 
 Performer::Performer()
 {
     daddy_perf_l_ = 0;
+    init_b_ =false;
 }
 
 Performer::~Performer()
@@ -32,23 +33,24 @@ Performer::get_mom() const
     return daddy_perf_l_->get_mom();
 }
 
-void
-Performer::midi_output( Midi_stream* )
-{
-}
-
 void 
 Performer::play_event( Midi_item* l ) 
 { 
     daddy_perf_l_->play_event( l ); 
 }
 
+int
+Performer::get_tempo_i()const
+{
+    return daddy_perf_l_->get_tempo_i();
+}
+
 void
 Performer::print() const
 {
 #ifndef NPRINT
     mtor << "\n" << name() << " {";
-//    do_print();
+    do_print();
     mtor << "}";
 #endif
 }
@@ -63,16 +65,42 @@ Performer::set( Moment )
 {
 } 
 
-void
-Performer::set_track( Midi_def*, int& )
-{
-} 
-
 bool 
-Performer::try_request( Request* req_l )
+Performer::do_try_request( Request* req_l )
 {
-// huh?
-//    return daddy_perf_l_->try_request( req_l_ );
     return false;
 }
 
+bool
+Performer::try_request(Request*r)
+{
+    if (!init_b_) { 
+       creation_processing();
+    }
+    return do_try_request(r);
+}
+
+void
+Performer::creation_processing()
+{
+    if (!init_b_) { 
+/*     if ( daddy_perf_l_ ) {
+           init_b_ = true;     // ugh. avoid recursion
+           daddy_perf_l_->creation_processing();
+           init_b_ = false;
+       }
+       
+       */
+       do_creation_processing();
+       init_b_ = true;
+    }
+}
+void
+Performer::do_creation_processing()
+{
+}
+
+void
+Performer::do_removal_processing()
+{
+}