+bool
+AutomationTimeAxisView::set_visibility (bool yn)
+{
+ bool changed = TimeAxisView::set_visibility (yn);
+
+ if (changed) {
+ get_state_node()->add_property ("shown", yn ? X_("yes") : X_("no"));
+ }
+
+ return changed;
+}
+
+/** @return true if this view has any automation data to display */
+bool
+AutomationTimeAxisView::has_automation () const
+{
+ return ( (_line && _line->npoints() > 0) || (_view && _view->has_automation()) );
+}
+
+list<boost::shared_ptr<AutomationLine> >
+AutomationTimeAxisView::lines () const
+{
+ list<boost::shared_ptr<AutomationLine> > lines;
+
+ if (_line) {
+ lines.push_back (_line);
+ } else if (_view) {
+ lines = _view->get_lines ();
+ }
+
+ return lines;
+}