diff layer/ImageLayer.cpp @ 806:4c8ca536b54f warnfix_no_size_t

Some more unsigned/long removal
author Chris Cannam
date Tue, 17 Jun 2014 15:36:56 +0100
parents 1d526ba11a24
children b66fb15de477
line wrap: on
line diff
--- a/layer/ImageLayer.cpp	Tue Jun 17 15:18:06 2014 +0100
+++ b/layer/ImageLayer.cpp	Tue Jun 17 15:36:56 2014 +0100
@@ -185,7 +185,7 @@
 	}
     }
 
-//    long useFrame = points.begin()->frame;
+//    int useFrame = points.begin()->frame;
 
 //    RealTime rt = RealTime::frame2RealTime(useFrame, m_model->getSampleRate());
 
@@ -292,8 +292,8 @@
 //    int x0 = rect.left(), x1 = rect.right();
     int x0 = 0, x1 = v->width();
 
-    long frame0 = v->getFrameForX(x0);
-    long frame1 = v->getFrameForX(x1);
+    int frame0 = v->getFrameForX(x0);
+    int frame1 = v->getFrameForX(x1);
 
     ImageModel::PointList points(m_model->getPoints(frame0, frame1));
     if (points.empty()) return;
@@ -563,7 +563,7 @@
 	return;
     }
 
-    long frame = v->getFrameForX(e->x());
+    int frame = v->getFrameForX(e->x());
     if (frame < 0) frame = 0;
     frame = frame / m_model->getResolution() * m_model->getResolution();
 
@@ -584,7 +584,7 @@
 
     if (!m_model || !m_editing) return;
 
-    long frame = v->getFrameForX(e->x());
+    int frame = v->getFrameForX(e->x());
     if (frame < 0) frame = 0;
     frame = frame / m_model->getResolution() * m_model->getResolution();
 
@@ -619,7 +619,7 @@
 }
 
 bool
-ImageLayer::addImage(long frame, QString url)
+ImageLayer::addImage(int frame, QString url)
 {
     QImage image(getLocalFilename(url));
     if (image.isNull()) {
@@ -664,8 +664,8 @@
 {
     if (!m_model || !m_editing) return;
 
-    long frameDiff = v->getFrameForX(e->x()) - v->getFrameForX(m_editOrigin.x());
-    long frame = m_originalPoint.frame + frameDiff;
+    int frameDiff = v->getFrameForX(e->x()) - v->getFrameForX(m_editOrigin.x());
+    int frame = m_originalPoint.frame + frameDiff;
 
     if (frame < 0) frame = 0;
     frame = (frame / m_model->getResolution()) * m_model->getResolution();