]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/staff-performer.cc
Issue 4569: Keep \autochange from escaping an existing context hierarchy
[lilypond.git] / lily / staff-performer.cc
index f635130b70267db6d154432c18447a3dc76acd92..ec4de3e9f8cabb2c66ac436e09ae22afddc168c0 100644 (file)
 #include "international.hh"
 #include "performer-group.hh"
 #include "warn.hh"
+#include "lily-imports.hh"
+
+#include "translator.icc"
+
+using std::deque;
+using std::map;
+using std::string;
 
 /* Perform a staff. Individual notes should have their instrument
   (staff-wide) set, so we override play_element ()
@@ -76,8 +83,6 @@ map<string, int> Staff_performer::static_channel_map_;
 int Staff_performer::channel_count_ = 0;
 int Staff_performer::staff_performer_count_ = 0;
 
-#include "translator.icc"
-
 ADD_TRANSLATOR (Staff_performer,
                 /* doc */
                 "",
@@ -199,8 +204,7 @@ Staff_performer::set_instrument (int channel, const string &voice)
   announce_element (Audio_element_info (instrument_, 0));
   Audio_staff *audio_staff = get_audio_staff (voice);
   audio_staff->add_audio_item (instrument_);
-  SCM proc = ly_lily_module_constant ("percussion?");
-  SCM drums = scm_call_1 (proc, ly_symbol2scm (instrument_string_.c_str ()));
+  SCM drums = Lily::percussion_p (ly_symbol2scm (instrument_string_.c_str ()));
   audio_staff->percussion_ = to_boolean (drums);
 }