]> code.delx.au - virtualtones/blobdiff - instrument.cpp
Remove unused include
[virtualtones] / instrument.cpp
index b4e729602f341f334b915bfd8d7cbbedb0f9a757..546100e2cb071905c9ad251dfe1e6edffce8dac9 100644 (file)
@@ -1,10 +1,12 @@
 // instrument.cpp - An instrument widget
-// Written by James Bunton <james@delx.cjb.net>
+// Written by James Bunton <james@delx.net.au>
 // Licensed under the GPL, see COPYING.txt for more details
 
 
 #include "instrument.h"
 
+using namespace Qt;
+
 
 Instrument::Instrument(QWidget *parent)
 : QWidget(parent, 0)
@@ -96,7 +98,7 @@ QString Instrument::midi2string(int num)
        for(octave = 0; num >= 12; octave++) {
                num -= 12;
        }
-       return QString(midnotes[num] + " - Octave: " + QString::number(octave - 6)); // Middle C is then "C - Octave: 3"
+       return QString(midnotes[num] + " - Octave: " + QString::number(octave - 2)); // Middle C is then "C - Octave: 3"
 }
 
 bool Instrument::checkSharp(int note)
@@ -112,5 +114,3 @@ bool Instrument::checkSharp(int note)
 
        return false;
 }
-
-