-rw-r--r-- | noncore/multimedia/tonleiter/config.in | 2 | ||||
-rw-r--r-- | noncore/multimedia/tonleiter/editinst.cpp | 11 | ||||
-rw-r--r-- | noncore/multimedia/tonleiter/fretboard.cpp | 13 | ||||
-rw-r--r-- | noncore/multimedia/tonleiter/tonleiter.pro | 6 | ||||
-rw-r--r-- | noncore/multimedia/tonleiter/tonleiterdata.cpp | 11 | ||||
-rw-r--r-- | noncore/multimedia/tonleiter/tonleiterdatahelper.cpp | 6 |
6 files changed, 29 insertions, 20 deletions
diff --git a/noncore/multimedia/tonleiter/config.in b/noncore/multimedia/tonleiter/config.in index d580ad7..9bd167e 100644 --- a/noncore/multimedia/tonleiter/config.in +++ b/noncore/multimedia/tonleiter/config.in @@ -2,3 +2,3 @@ boolean "tonleiter (shows scales on sting instruments)" default "n" - depends ( LIBQPE || LIBQPE-X11 ) + depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE diff --git a/noncore/multimedia/tonleiter/editinst.cpp b/noncore/multimedia/tonleiter/editinst.cpp index ccb4560..a8c20c8 100644 --- a/noncore/multimedia/tonleiter/editinst.cpp +++ b/noncore/multimedia/tonleiter/editinst.cpp @@ -1,7 +1,12 @@ #include "editinst.h" -#include <qpushbutton.h> - +/* OPIE */ +#include <opie2/odebug.h> +#include <qpe/config.h> #include <qpe/qpeapplication.h> +using namespace Opie::Core; + +/* QT */ +#include <qpushbutton.h> Menu::InstEditDialog::InstEditDialog(TonleiterData* data,QWidget* parent,const char* name) @@ -101,5 +106,5 @@ void Menu::InstEditDialog::loadInstrument() stringlist.clear(); Instrument inst=data->getInstrument(instid); - qDebug("load Instrument : %d strings",inst.noOfStrings()); + odebug << "load Instrument : " << inst.noOfStrings() << " strings" << oendl; for(uint s=0;s<inst.noOfStrings();s++) { diff --git a/noncore/multimedia/tonleiter/fretboard.cpp b/noncore/multimedia/tonleiter/fretboard.cpp index 7e63e01..58bdb86 100644 --- a/noncore/multimedia/tonleiter/fretboard.cpp +++ b/noncore/multimedia/tonleiter/fretboard.cpp @@ -1,4 +1,9 @@ #include "fretboard.h" +/* OPIE */ +#include <opie2/odebug.h> +using namespace Opie::Core; + +/* QT */ #include <qpainter.h> @@ -28,5 +33,5 @@ void Graph::FretBoard::paintEvent(QPaintEvent* pe) int instid=data->getCurrentInstrumentID(); inst=data->getInstrument(instid); - //qDebug("inst %d is %s",instid,inst.instName().data()); + //odebug << "inst " << instid << " is " << inst.instName().data() << "" << oendl; QRect mysize=rect(); @@ -144,8 +149,8 @@ void Graph::FretBoard::paintScale(QPainter* p) int octave=Note::octaveOfBaseNote(data->getCurrentBaseNote(),note)-baseoctave; if(octave<0) - qDebug("%d,%d",octave,baseoctave); + odebug << "" << octave << "," << baseoctave << "" << oendl; if(octave>5) { - qDebug("octave out of range"); + odebug << "octave out of range" << oendl; octave=5; } @@ -154,5 +159,5 @@ void Graph::FretBoard::paintScale(QPainter* p) int c= ( (note-12*baseoctave) - (12*octave+data->getCurrentBaseNote()) )*15; if(c<0 || c>255) - qDebug("%d = %d - ( %d + %d)",c,note,12*octave,data->getCurrentBaseNote()); + odebug << "" << c << " = " << note << " - ( " << 12*octave << " + " << data->getCurrentBaseNote() << ")" << oendl; QColor dotcolor(255,255,255); diff --git a/noncore/multimedia/tonleiter/tonleiter.pro b/noncore/multimedia/tonleiter/tonleiter.pro index 4bd1bc2..4be3bef 100644 --- a/noncore/multimedia/tonleiter/tonleiter.pro +++ b/noncore/multimedia/tonleiter/tonleiter.pro @@ -1,4 +1,3 @@ TEMPLATE = app -#CONFIG = qt warn_on CONFIG = qt warn_on HEADERS = mainwidget.h tonleiterdata.h tonleiterdatahelper.h fretboard.h menuwidget.h editinst.h editstringwidget.h editscale.h pianoscale.h @@ -6,8 +5,7 @@ SOURCES = mainwidget.cpp tonleiterdata.cpp tonleiterdatahelper.cpp fretboard.c INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include -LIBS += -lqpe -INTERFACES = +LIBS += -lqpe -lopiecore2 TARGET = tonleiter DESTDIR = $(OPIEDIR)/bin -#TMAKE_CXXFLAGS += -DQT_QWS_VERCEL_IDR -DQWS -fno-exceptions -fno-rtti + include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/multimedia/tonleiter/tonleiterdata.cpp b/noncore/multimedia/tonleiter/tonleiterdata.cpp index 33b3c49..564b7f0 100644 --- a/noncore/multimedia/tonleiter/tonleiterdata.cpp +++ b/noncore/multimedia/tonleiter/tonleiterdata.cpp @@ -1,8 +1,9 @@ #include "tonleiterdata.h" - -#include <qpe/config.h> - using namespace Data; +/* OPIE */ +#include <opie2/odebug.h> +#include <qpe/config.h> +using namespace Opie::Core; TonleiterData::TonleiterData(QObject* parent) @@ -153,5 +154,5 @@ Instrument TonleiterData::getInstrument(int id) else { - qDebug("undefined insrtument %d of %d",id,instruments.count()); + odebug << "undefined insrtument " << id << " of " << instruments.count() << "" << oendl; return Instrument(); } @@ -175,5 +176,5 @@ Scale TonleiterData::getScale(int id) else { - qDebug("Undefined scale"); + odebug << "Undefined scale" << oendl; return Scale(); } diff --git a/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp b/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp index d904a71..285d2c1 100644 --- a/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp +++ b/noncore/multimedia/tonleiter/tonleiterdatahelper.cpp @@ -35,5 +35,5 @@ int Note::octaveOfBaseNote(int base,int note) int normnote = (note>=base) ? note-base : (12-base)+note; int octave=getOctaveOfNote(normnote); - //qDebug("note %d of %d base is norm %d -> ocatve %d",note,base,normnote,octave); + //odebug << "note " << note << " of " << base << " base is norm " << normnote << " -> ocatve " << octave << "" << oendl; return octave; } @@ -132,10 +132,10 @@ bool Scale::noteInScale(int base,int note) if(halftones.contains(normnote)>0) { - //qDebug("OK : base : %d, note %d -> norm %d",base,note,normnote); + //odebug << "OK : base : " << base << ", note " << note << " -> norm " << normnote << "" << oendl; return true; } else { - //qDebug("BAD : base : %d, note %d -> norm %d",base,note,normnote); + //odebug << "BAD : base : " << base << ", note " << note << " -> norm " << normnote << "" << oendl; return false; } |