+
+
+Sequencer::ActionDefLoader::ActionDefLoader(Sequencer &s, Demo &d):
+ DataFile::ObjectLoader<Sequencer>(s),
+ demo(d)
+{
+ obj.action_registry.add_all(*this);
+}
+
+
+Sequencer::SegmentLoader::SegmentLoader(Sequencer &s, float b, float e, Demo &d):
+ ActionDefLoader(s, d),
+ start_beat(b),
+ end_beat(e)
+{
+ add("apply", &SegmentLoader::apply);
+}
+
+void Sequencer::SegmentLoader::action_loaded()
+{
+ obj.add_action(*action, start_beat, end_beat);
+ obj.anonymous_actions.push_back(action.release());
+}
+
+void Sequencer::SegmentLoader::apply(const string &n)
+{
+ obj.add_action(*get_item(obj.named_actions, n), start_beat, end_beat);
+}
+
+} // namespace DemoScene
+} // namespace Msp