changeset 286:7554ae119882

* Fix failure to save vertical scale setting from time-value layer
author Chris Cannam
date Wed, 11 Jul 2007 20:46:37 +0000
parents 9dd432665059
children cd2492c5fe45
files layer/TimeValueLayer.cpp
diffstat 1 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/layer/TimeValueLayer.cpp	Wed Jul 11 17:21:37 2007 +0000
+++ b/layer/TimeValueLayer.cpp	Wed Jul 11 20:46:37 2007 +0000
@@ -1424,8 +1424,9 @@
 TimeValueLayer::toXmlString(QString indent, QString extraAttributes) const
 {
     return Layer::toXmlString(indent, extraAttributes +
-			      QString(" colour=\"%1\" plotStyle=\"%2\"")
-			      .arg(encodeColour(m_colour)).arg(m_plotStyle));
+			      QString(" colour=\"%1\" plotStyle=\"%2\" verticalScale=\"%3\"")
+			      .arg(encodeColour(m_colour)).arg(m_plotStyle)
+                              .arg(m_verticalScale));
 }
 
 void
@@ -1443,5 +1444,9 @@
     PlotStyle style = (PlotStyle)
 	attributes.value("plotStyle").toInt(&ok);
     if (ok) setPlotStyle(style);
+
+    VerticalScale scale = (VerticalScale)
+	attributes.value("verticalScale").toInt(&ok);
+    if (ok) setVerticalScale(scale);
 }