Diffstat (limited to 'noncore/multimedia/tonleiter/editinst.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/multimedia/tonleiter/editinst.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
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,17 +1,22 @@ | |||
1 | #include "editinst.h" | 1 | #include "editinst.h" |
2 | 2 | ||
3 | #include <qpushbutton.h> | 3 | /* OPIE */ |
4 | 4 | #include <opie2/odebug.h> | |
5 | #include <qpe/config.h> | ||
5 | #include <qpe/qpeapplication.h> | 6 | #include <qpe/qpeapplication.h> |
7 | using namespace Opie::Core; | ||
8 | |||
9 | /* QT */ | ||
10 | #include <qpushbutton.h> | ||
6 | 11 | ||
7 | Menu::InstEditDialog::InstEditDialog(TonleiterData* data,QWidget* parent,const char* name) | 12 | Menu::InstEditDialog::InstEditDialog(TonleiterData* data,QWidget* parent,const char* name) |
8 | :QDialog(parent,name,true,0),data(data) | 13 | :QDialog(parent,name,true,0),data(data) |
9 | { | 14 | { |
10 | setCaption("Tonleiter::"+tr("Instrument")); | 15 | setCaption("Tonleiter::"+tr("Instrument")); |
11 | QBoxLayout* masterlayout=new QBoxLayout(this,QBoxLayout::TopToBottom); | 16 | QBoxLayout* masterlayout=new QBoxLayout(this,QBoxLayout::TopToBottom); |
12 | instid=data->getCurrentInstrumentID(); | 17 | instid=data->getCurrentInstrumentID(); |
13 | stringlist.setAutoDelete(true); | 18 | stringlist.setAutoDelete(true); |
14 | 19 | ||
15 | QBoxLayout* toplayout=new QBoxLayout(masterlayout,QBoxLayout::LeftToRight); | 20 | QBoxLayout* toplayout=new QBoxLayout(masterlayout,QBoxLayout::LeftToRight); |
16 | 21 | ||
17 | //Name combo + Add + Delete | 22 | //Name combo + Add + Delete |
@@ -91,20 +96,20 @@ void Menu::InstEditDialog::deleteString(int id) | |||
91 | } | 96 | } |
92 | //**************************************************************************** | 97 | //**************************************************************************** |
93 | void Menu::InstEditDialog::saveInstrument() | 98 | void Menu::InstEditDialog::saveInstrument() |
94 | { | 99 | { |
95 | //auto delete is set to true so widgets _should_ be deleted | 100 | //auto delete is set to true so widgets _should_ be deleted |
96 | stringlist.clear(); | 101 | stringlist.clear(); |
97 | } | 102 | } |
98 | //**************************************************************************** | 103 | //**************************************************************************** |
99 | void Menu::InstEditDialog::loadInstrument() | 104 | void Menu::InstEditDialog::loadInstrument() |
100 | { | 105 | { |
101 | stringlist.clear(); | 106 | stringlist.clear(); |
102 | Instrument inst=data->getInstrument(instid); | 107 | Instrument inst=data->getInstrument(instid); |
103 | qDebug("load Instrument : %d strings",inst.noOfStrings()); | 108 | odebug << "load Instrument : " << inst.noOfStrings() << " strings" << oendl; |
104 | for(uint s=0;s<inst.noOfStrings();s++) | 109 | for(uint s=0;s<inst.noOfStrings();s++) |
105 | { | 110 | { |
106 | stringlist.append(new EditStringWidget(inst.string(s),stringwidget)); | 111 | stringlist.append(new EditStringWidget(inst.string(s),stringwidget)); |
107 | } | 112 | } |
108 | } | 113 | } |
109 | //**************************************************************************** | 114 | //**************************************************************************** |
110 | //**************************************************************************** | 115 | //**************************************************************************** |