]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/glissando-engraver.cc
Imported Upstream version 2.19.45
[lilypond.git] / lily / glissando-engraver.cc
index 711bb1df81690d7df8d858825c122b1e2b56eec9..878e7f88b355539a7f29e1cf75aa3e3e701108be 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2000--2012 Jan Nieuwenhuizen <janneke@gnu.org>
+  Copyright (C) 2000--2015 Jan Nieuwenhuizen <janneke@gnu.org>
 
   LilyPond is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -35,8 +35,8 @@ public:
   TRANSLATOR_DECLARATIONS (Glissando_engraver);
 
 protected:
-  DECLARE_TRANSLATOR_LISTENER (glissando);
-  DECLARE_ACKNOWLEDGER (note_column);
+  void listen_glissando (Stream_event *);
+  void acknowledge_note_column (Grob_info);
   virtual void finalize ();
 
   void stop_translation_timestep ();
@@ -60,7 +60,6 @@ Glissando_engraver::Glissando_engraver ()
   stop_glissandi_ = false;
 }
 
-IMPLEMENT_TRANSLATOR_LISTENER (Glissando_engraver, glissando);
 void
 Glissando_engraver::listen_glissando (Stream_event *ev)
 {
@@ -110,7 +109,7 @@ Glissando_engraver::acknowledge_note_column (Grob_info info)
     {
       extract_grob_set (g, "note-heads", note_heads);
       SCM map = get_property ("glissandoMap");
-      if (map == SCM_EOL)
+      if (scm_is_null (map))
         for (vsize i = 0; i < note_heads.size (); i++)
           {
             note_column_1.push_back (i);
@@ -170,7 +169,13 @@ Glissando_engraver::finalize ()
     kill_me_[i]->suicide ();
 }
 
-ADD_ACKNOWLEDGER (Glissando_engraver, note_column);
+void
+Glissando_engraver::boot ()
+{
+  ADD_LISTENER (Glissando_engraver, glissando);
+  ADD_ACKNOWLEDGER (Glissando_engraver, note_column);
+}
+
 ADD_TRANSLATOR (Glissando_engraver,
                 /* doc */
                 "Engrave glissandi.",