diff base/Clipboard.cpp @ 911:73c2fd9a7dbe

Merge from branch tony_integration
author Chris Cannam
date Wed, 14 May 2014 09:54:20 +0100
parents afeb580b1b57
children 6a94bb528e9d
line wrap: on
line diff
--- a/base/Clipboard.cpp	Wed May 07 15:17:58 2014 +0100
+++ b/base/Clipboard.cpp	Wed May 14 09:54:20 2014 +0100
@@ -123,6 +123,15 @@
     return m_frame;
 }
 
+Clipboard::Point
+Clipboard::Point::withFrame(long frame) const
+{
+    Point p(*this);
+    p.m_haveFrame = true;
+    p.m_frame = frame;
+    return p;
+}
+
 bool
 Clipboard::Point::haveValue() const
 {
@@ -135,6 +144,15 @@
     return m_value;
 }
 
+Clipboard::Point
+Clipboard::Point::withValue(float value) const
+{
+    Point p(*this);
+    p.m_haveValue = true;
+    p.m_value = value;
+    return p;
+}
+
 bool
 Clipboard::Point::haveDuration() const
 {
@@ -147,6 +165,15 @@
     return m_duration;
 }
 
+Clipboard::Point
+Clipboard::Point::withDuration(size_t duration) const
+{
+    Point p(*this);
+    p.m_haveDuration = true;
+    p.m_duration = duration;
+    return p;
+}
+
 bool
 Clipboard::Point::haveLabel() const
 {
@@ -159,6 +186,15 @@
     return m_label;
 }
 
+Clipboard::Point
+Clipboard::Point::withLabel(QString label) const
+{
+    Point p(*this);
+    p.m_haveLabel = true;
+    p.m_label = label;
+    return p;
+}
+
 bool
 Clipboard::Point::haveLevel() const
 {
@@ -171,6 +207,15 @@
     return m_level;
 }
 
+Clipboard::Point
+Clipboard::Point::withLevel(float level) const
+{
+    Point p(*this);
+    p.m_haveLevel = true;
+    p.m_level = level;
+    return p;
+}
+
 bool
 Clipboard::Point::haveReferenceFrame() const
 {