Const-correctness fixes

This commit is contained in:
Colin Wallace
2015-09-06 15:04:46 -07:00
parent 68da3ad64f
commit 6a9e105c90
2 changed files with 5 additions and 5 deletions

View File

@@ -126,7 +126,7 @@ protected:
int getKey( int y ) const;
static inline void drawNoteRect( QPainter & p, int x, int y,
int width, Note * n, const QColor & noteCol );
int width, const Note * n, const QColor & noteCol );
void removeSelection();
void selectAll();
void getSelectedNotes( NoteVector & selected_notes );
@@ -326,7 +326,7 @@ private:
void copy_to_clipboard(const NoteVector & notes ) const;
void drawDetuningInfo( QPainter & _p, Note * _n, int _x, int _y );
void drawDetuningInfo( QPainter & _p, const Note * _n, int _x, int _y ) const;
bool mouseOverNote();
Note * noteUnderMouse();

View File

@@ -702,7 +702,7 @@ void PianoRoll::setBarColor( const QColor & c )
inline void PianoRoll::drawNoteRect(QPainter & p, int x, int y,
int width, Note * n, const QColor & noteCol )
int width, const Note * n, const QColor & noteCol )
{
++x;
++y;
@@ -770,8 +770,8 @@ inline void PianoRoll::drawNoteRect(QPainter & p, int x, int y,
inline void PianoRoll::drawDetuningInfo( QPainter & _p, Note * _n, int _x,
int _y )
inline void PianoRoll::drawDetuningInfo( QPainter & _p, const Note * _n, int _x,
int _y ) const
{
int middle_y = _y + KEY_LINE_HEIGHT / 2;
_p.setPen( noteColor() );