Mercurial > hg > svgui
comparison layer/NoteLayer.cpp @ 718:e5f4385615ac tony_integration
Merge from tonioni branch
author | Chris Cannam |
---|---|
date | Tue, 28 Jan 2014 15:02:09 +0000 |
parents | 137d3ff48f73 |
children | 1d526ba11a24 |
comparison
equal
deleted
inserted
replaced
704:b81f21f2c4c3 | 718:e5f4385615ac |
---|---|
54 m_editingCommand(0), | 54 m_editingCommand(0), |
55 m_verticalScale(AutoAlignScale), | 55 m_verticalScale(AutoAlignScale), |
56 m_scaleMinimum(0), | 56 m_scaleMinimum(0), |
57 m_scaleMaximum(0) | 57 m_scaleMaximum(0) |
58 { | 58 { |
59 | 59 SVDEBUG << "constructed NoteLayer" << endl; |
60 } | 60 } |
61 | 61 |
62 void | 62 void |
63 NoteLayer::setModel(NoteModel *model) | 63 NoteLayer::setModel(NoteModel *model) |
64 { | 64 { |
65 if (m_model == model) return; | 65 if (m_model == model) return; |
66 m_model = model; | 66 m_model = model; |
67 | 67 |
68 connectSignals(m_model); | 68 connectSignals(m_model); |
69 | 69 |
840 } | 840 } |
841 | 841 |
842 void | 842 void |
843 NoteLayer::paintVerticalScale(View *v, bool, QPainter &paint, QRect) const | 843 NoteLayer::paintVerticalScale(View *v, bool, QPainter &paint, QRect) const |
844 { | 844 { |
845 if (!m_model) return; | 845 if (!m_model || m_model->getPoints().empty()) return; |
846 | 846 |
847 QString unit; | 847 QString unit; |
848 float min, max; | 848 float min, max; |
849 bool logarithmic; | 849 bool logarithmic; |
850 | 850 |