Mercurial > hg > svgui
comparison view/View.cpp @ 354:94ada7dbae3c
* Add plugin version to Transform record
* Warn when the plugin version being used to restore or regenerate a layer
is not the same as the one originally used to create it
author | Chris Cannam |
---|---|
date | Fri, 25 Jan 2008 18:15:57 +0000 |
parents | ac954fc0ec6f |
children | 9aab6bd27fcc |
comparison
equal
deleted
inserted
replaced
353:de4db9b5dcf1 | 354:94ada7dbae3c |
---|---|
349 long | 349 long |
350 View::getFrameForX(int x) const | 350 View::getFrameForX(int x) const |
351 { | 351 { |
352 long z = (long)m_zoomLevel; | 352 long z = (long)m_zoomLevel; |
353 long frame = m_centreFrame - (width()/2) * z; | 353 long frame = m_centreFrame - (width()/2) * z; |
354 | |
355 std::cerr << "View::getFrameForX(" << x << "): z = " << z << ", m_centreFrame = " << m_centreFrame << ", width() = " << width() << ", frame = " << frame << std::endl; | |
356 | |
354 frame = (frame / z) * z; // this is start frame | 357 frame = (frame / z) * z; // this is start frame |
355 return frame + x * z; | 358 return frame + x * z; |
356 } | 359 } |
357 | 360 |
358 float | 361 float |