diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-09-06 20:59:29 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-09-06 20:59:29 +0000 |
commit | 11f31c37e5fa4889d9989f10272f44845449cb7b (patch) | |
tree | 4383da04a76c497950d957fc6120b0fd0d9082c2 /src/gui/studio/BankEditorDialog.cpp | |
parent | 832eb69d571e8e518db45d0c0e6fbc0f00690209 (diff) | |
download | rosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.tar.gz rosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.zip |
Initial TQt conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/rosegarden@1172292 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/gui/studio/BankEditorDialog.cpp')
-rw-r--r-- | src/gui/studio/BankEditorDialog.cpp | 262 |
1 files changed, 131 insertions, 131 deletions
diff --git a/src/gui/studio/BankEditorDialog.cpp b/src/gui/studio/BankEditorDialog.cpp index 20aaf2d..5c5c3d2 100644 --- a/src/gui/studio/BankEditorDialog.cpp +++ b/src/gui/studio/BankEditorDialog.cpp @@ -24,7 +24,7 @@ #include "BankEditorDialog.h" -#include <qlayout.h> +#include <tqlayout.h> #include <kapplication.h> #include <klocale.h> @@ -58,27 +58,27 @@ #include <kstdaccel.h> #include <kstdaction.h> #include <kxmlguiclient.h> -#include <qcheckbox.h> -#include <qdialog.h> -#include <qdir.h> -#include <qfileinfo.h> -#include <qframe.h> -#include <qgroupbox.h> -#include <qhbox.h> -#include <qpushbutton.h> -#include <qsizepolicy.h> -#include <qsplitter.h> -#include <qstring.h> -#include <qtooltip.h> -#include <qvbox.h> -#include <qvgroupbox.h> -#include <qwidget.h> +#include <tqcheckbox.h> +#include <tqdialog.h> +#include <tqdir.h> +#include <tqfileinfo.h> +#include <tqframe.h> +#include <tqgroupbox.h> +#include <tqhbox.h> +#include <tqpushbutton.h> +#include <tqsizepolicy.h> +#include <tqsplitter.h> +#include <tqstring.h> +#include <tqtooltip.h> +#include <tqvbox.h> +#include <tqvgroupbox.h> +#include <tqwidget.h> namespace Rosegarden { -BankEditorDialog::BankEditorDialog(QWidget *parent, +BankEditorDialog::BankEditorDialog(TQWidget *parent, RosegardenGUIDoc *doc, DeviceId defaultDevice): KMainWindow(parent, "bankeditordialog"), @@ -91,22 +91,22 @@ BankEditorDialog::BankEditorDialog(QWidget *parent, m_lastDevice(Device::NO_DEVICE), m_updateDeviceList(false) { - QVBox* mainFrame = new QVBox(this); + TQVBox* mainFrame = new TQVBox(this); setCentralWidget(mainFrame); setCaption(i18n("Manage MIDI Banks and Programs")); - QSplitter* splitter = new QSplitter(mainFrame); + TQSplitter* splitter = new TQSplitter(mainFrame); - QFrame* btnBox = new QFrame(mainFrame); + TQFrame* btnBox = new TQFrame(mainFrame); - btnBox->setSizePolicy(QSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed)); + btnBox->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed)); - QHBoxLayout* layout = new QHBoxLayout(btnBox, 4, 10); + TQHBoxLayout* layout = new TQHBoxLayout(btnBox, 4, 10); - m_closeButton = new QPushButton(btnBox); - m_applyButton = new QPushButton(i18n("Apply"), btnBox); - m_resetButton = new QPushButton(i18n("Reset"), btnBox); + m_closeButton = new TQPushButton(btnBox); + m_applyButton = new TQPushButton(i18n("Apply"), btnBox); + m_resetButton = new TQPushButton(i18n("Reset"), btnBox); layout->addStretch(10); layout->addWidget(m_applyButton); @@ -115,15 +115,15 @@ BankEditorDialog::BankEditorDialog(QWidget *parent, layout->addWidget(m_closeButton); layout->addSpacing(5); - connect(m_applyButton, SIGNAL(clicked()), - this, SLOT(slotApply())); - connect(m_resetButton, SIGNAL(clicked()), - this, SLOT(slotReset())); + connect(m_applyButton, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotApply())); + connect(m_resetButton, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotReset())); // // Left-side list view // - QVBox* leftPart = new QVBox(splitter); + TQVBox* leftPart = new TQVBox(splitter); m_listView = new KListView(leftPart); m_listView->addColumn(i18n("MIDI Device")); m_listView->addColumn(i18n("Type")); @@ -134,13 +134,13 @@ BankEditorDialog::BankEditorDialog(QWidget *parent, m_listView->setItemsRenameable(true); m_listView->restoreLayout(kapp->config(), BankEditorConfigGroup); - QFrame *bankBox = new QFrame(leftPart); - QGridLayout *gridLayout = new QGridLayout(bankBox, 4, 2, 6, 6); + TQFrame *bankBox = new TQFrame(leftPart); + TQGridLayout *gridLayout = new TQGridLayout(bankBox, 4, 2, 6, 6); - m_addBank = new QPushButton(i18n("Add Bank"), bankBox); - m_addKeyMapping = new QPushButton(i18n("Add Key Mapping"), bankBox); - m_delete = new QPushButton(i18n("Delete"), bankBox); - m_deleteAll = new QPushButton(i18n("Delete All"), bankBox); + m_addBank = new TQPushButton(i18n("Add Bank"), bankBox); + m_addKeyMapping = new TQPushButton(i18n("Add Key Mapping"), bankBox); + m_delete = new TQPushButton(i18n("Delete"), bankBox); + m_deleteAll = new TQPushButton(i18n("Delete All"), bankBox); gridLayout->addWidget(m_addBank, 0, 0); gridLayout->addWidget(m_addKeyMapping, 0, 1); gridLayout->addWidget(m_delete, 1, 0); @@ -148,56 +148,56 @@ BankEditorDialog::BankEditorDialog(QWidget *parent, // Tips // - QToolTip::add + TQToolTip::add (m_addBank, i18n("Add a Bank to the current device")); - QToolTip::add + TQToolTip::add (m_addKeyMapping, i18n("Add a Percussion Key Mapping to the current device")); - QToolTip::add + TQToolTip::add (m_delete, i18n("Delete the current Bank or Key Mapping")); - QToolTip::add + TQToolTip::add (m_deleteAll, i18n("Delete all Banks and Key Mappings from the current Device")); - m_importBanks = new QPushButton(i18n("Import..."), bankBox); - m_exportBanks = new QPushButton(i18n("Export..."), bankBox); + m_importBanks = new TQPushButton(i18n("Import..."), bankBox); + m_exportBanks = new TQPushButton(i18n("Export..."), bankBox); gridLayout->addWidget(m_importBanks, 2, 0); gridLayout->addWidget(m_exportBanks, 2, 1); // Tips // - QToolTip::add + TQToolTip::add (m_importBanks, i18n("Import Bank and Program data from a Rosegarden file to the current Device")); - QToolTip::add + TQToolTip::add (m_exportBanks, i18n("Export all Device and Bank information to a Rosegarden format interchange file")); - m_copyPrograms = new QPushButton(i18n("Copy"), bankBox); - m_pastePrograms = new QPushButton(i18n("Paste"), bankBox); + m_copyPrograms = new TQPushButton(i18n("Copy"), bankBox); + m_pastePrograms = new TQPushButton(i18n("Paste"), bankBox); gridLayout->addWidget(m_copyPrograms, 3, 0); gridLayout->addWidget(m_pastePrograms, 3, 1); // Tips // - QToolTip::add + TQToolTip::add (m_copyPrograms, i18n("Copy all Program names from current Bank to clipboard")); - QToolTip::add + TQToolTip::add (m_pastePrograms, i18n("Paste Program names from clipboard to current Bank")); - connect(m_listView, SIGNAL(currentChanged(QListViewItem*)), - this, SLOT(slotPopulateDevice(QListViewItem*))); + connect(m_listView, TQT_SIGNAL(currentChanged(TQListViewItem*)), + this, TQT_SLOT(slotPopulateDevice(TQListViewItem*))); - QFrame *vbox = new QFrame(splitter); - QVBoxLayout *vboxLayout = new QVBoxLayout(vbox, 8, 6); + TQFrame *vbox = new TQFrame(splitter); + TQVBoxLayout *vboxLayout = new TQVBoxLayout(vbox, 8, 6); m_programEditor = new MidiProgramsEditor(this, vbox); vboxLayout->addWidget(m_programEditor); @@ -206,57 +206,57 @@ BankEditorDialog::BankEditorDialog(QWidget *parent, vboxLayout->addWidget(m_keyMappingEditor); m_keyMappingEditor->hide(); - m_programEditor->setSizePolicy(QSizePolicy(QSizePolicy::Minimum, QSizePolicy::Preferred)); - m_keyMappingEditor->setSizePolicy(QSizePolicy(QSizePolicy::Minimum, QSizePolicy::Preferred)); + m_programEditor->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Preferred)); + m_keyMappingEditor->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Preferred)); - m_optionBox = new QVGroupBox(i18n("Options"), vbox); + m_optionBox = new TQVGroupBox(i18n("Options"), vbox); vboxLayout->addWidget(m_optionBox); - QHBox *variationBox = new QHBox(m_optionBox); - m_variationToggle = new QCheckBox(i18n("Show Variation list based on "), variationBox); + TQHBox *variationBox = new TQHBox(m_optionBox); + m_variationToggle = new TQCheckBox(i18n("Show Variation list based on "), variationBox); m_variationCombo = new KComboBox(variationBox); m_variationCombo->insertItem(i18n("LSB")); m_variationCombo->insertItem(i18n("MSB")); // device/bank modification - connect(m_listView, SIGNAL(itemRenamed (QListViewItem*, const QString&, int)), - this, SLOT(slotModifyDeviceOrBankName(QListViewItem*, const QString&, int))); + connect(m_listView, TQT_SIGNAL(itemRenamed (TQListViewItem*, const TQString&, int)), + this, TQT_SLOT(slotModifyDeviceOrBankName(TQListViewItem*, const TQString&, int))); - connect(m_addBank, SIGNAL(clicked()), - this, SLOT(slotAddBank())); + connect(m_addBank, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotAddBank())); - connect(m_addKeyMapping, SIGNAL(clicked()), - this, SLOT(slotAddKeyMapping())); + connect(m_addKeyMapping, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotAddKeyMapping())); - connect(m_delete, SIGNAL(clicked()), - this, SLOT(slotDelete())); + connect(m_delete, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotDelete())); - connect(m_deleteAll, SIGNAL(clicked()), - this, SLOT(slotDeleteAll())); + connect(m_deleteAll, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotDeleteAll())); - connect(m_importBanks, SIGNAL(clicked()), - this, SLOT(slotImport())); + connect(m_importBanks, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotImport())); - connect(m_exportBanks, SIGNAL(clicked()), - this, SLOT(slotExport())); + connect(m_exportBanks, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotExport())); - connect(m_copyPrograms, SIGNAL(clicked()), - this, SLOT(slotEditCopy())); + connect(m_copyPrograms, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotEditCopy())); - connect(m_pastePrograms, SIGNAL(clicked()), - this, SLOT(slotEditPaste())); + connect(m_pastePrograms, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotEditPaste())); - connect(m_variationToggle, SIGNAL(clicked()), - this, SLOT(slotVariationToggled())); + connect(m_variationToggle, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotVariationToggled())); - connect(m_variationCombo, SIGNAL(activated(int)), - this, SLOT(slotVariationChanged(int))); + connect(m_variationCombo, TQT_SIGNAL(activated(int)), + this, TQT_SLOT(slotVariationChanged(int))); setupActions(); m_doc->getCommandHistory()->attachView(actionCollection()); - connect(m_doc->getCommandHistory(), SIGNAL(commandExecuted()), - this, SLOT(slotUpdate())); + connect(m_doc->getCommandHistory(), TQT_SIGNAL(commandExecuted()), + this, TQT_SLOT(slotUpdate())); // Initialise the dialog // @@ -303,14 +303,14 @@ BankEditorDialog::~BankEditorDialog() void BankEditorDialog::setupActions() { - KAction* close = KStdAction::close (this, SLOT(slotFileClose()), actionCollection()); + KAction* close = KStdAction::close (this, TQT_SLOT(slotFileClose()), actionCollection()); m_closeButton->setText(close->text()); - connect(m_closeButton, SIGNAL(clicked()), - this, SLOT(slotFileClose())); + connect(m_closeButton, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotFileClose())); - KStdAction::copy (this, SLOT(slotEditCopy()), actionCollection()); - KStdAction::paste (this, SLOT(slotEditPaste()), actionCollection()); + KStdAction::copy (this, TQT_SLOT(slotEditCopy()), actionCollection()); + KStdAction::paste (this, TQT_SLOT(slotEditPaste()), actionCollection()); // some adjustments @@ -355,12 +355,12 @@ BankEditorDialog::initDialog() continue; m_deviceNameMap[midiDevice->getId()] = midiDevice->getName(); - QString itemName = strtoqstr(midiDevice->getName()); + TQString itemName = strtoqstr(midiDevice->getName()); RG_DEBUG << "BankEditorDialog::initDialog - adding " << itemName << endl; - QListViewItem* deviceItem = new MidiDeviceListViewItem + TQListViewItem* deviceItem = new MidiDeviceListViewItem (midiDevice->getId(), m_listView, itemName); deviceItem->setOpen(true); @@ -401,7 +401,7 @@ BankEditorDialog::updateDialog() if (m_deviceNameMap.find(midiDevice->getId()) != m_deviceNameMap.end()) { // Device already displayed but make sure the label is up to date // - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); if (currentItem) { MidiDeviceListViewItem* deviceItem = @@ -425,7 +425,7 @@ BankEditorDialog::updateDialog() deviceLabelUpdate = true; } - QListViewItem *child = deviceItem->firstChild(); + TQListViewItem *child = deviceItem->firstChild(); while (child) { @@ -454,12 +454,12 @@ BankEditorDialog::updateDialog() } m_deviceNameMap[midiDevice->getId()] = midiDevice->getName(); - QString itemName = strtoqstr(midiDevice->getName()); + TQString itemName = strtoqstr(midiDevice->getName()); RG_DEBUG << "BankEditorDialog::updateDialog - adding " << itemName << endl; - QListViewItem* deviceItem = new MidiDeviceListViewItem + TQListViewItem* deviceItem = new MidiDeviceListViewItem (midiDevice->getId(), m_listView, itemName); deviceItem->setOpen(true); @@ -496,7 +496,7 @@ BankEditorDialog::updateDialog() void BankEditorDialog::setCurrentDevice(DeviceId device) { - for (QListViewItem *item = m_listView->firstChild(); item; + for (TQListViewItem *item = m_listView->firstChild(); item; item = item->nextSibling()) { MidiDeviceListViewItem * deviceItem = dynamic_cast<MidiDeviceListViewItem *>(item); @@ -508,11 +508,11 @@ BankEditorDialog::setCurrentDevice(DeviceId device) } void -BankEditorDialog::populateDeviceItem(QListViewItem* deviceItem, MidiDevice* midiDevice) +BankEditorDialog::populateDeviceItem(TQListViewItem* deviceItem, MidiDevice* midiDevice) { clearItemChildren(deviceItem); - QString itemName = strtoqstr(midiDevice->getName()); + TQString itemName = strtoqstr(midiDevice->getName()); BankList banks = midiDevice->getBanks(); // add banks for this device @@ -545,7 +545,7 @@ BankEditorDialog::updateDeviceItem(MidiDeviceListViewItem* deviceItem) return ; } - QString itemName = strtoqstr(midiDevice->getName()); + TQString itemName = strtoqstr(midiDevice->getName()); BankList banks = midiDevice->getBanks(); KeyMappingList keymaps = midiDevice->getKeyMappings(); @@ -567,7 +567,7 @@ BankEditorDialog::updateDeviceItem(MidiDeviceListViewItem* deviceItem) for (unsigned int i = 0; i < keymaps.size(); ++i) { - QListViewItem *child = deviceItem->firstChild(); + TQListViewItem *child = deviceItem->firstChild(); bool have = false; while (child) { @@ -593,9 +593,9 @@ BankEditorDialog::updateDeviceItem(MidiDeviceListViewItem* deviceItem) // delete banks which are no longer present // - std::vector<QListViewItem*> childrenToDelete; + std::vector<TQListViewItem*> childrenToDelete; - QListViewItem* child = deviceItem->firstChild(); + TQListViewItem* child = deviceItem->firstChild(); while (child) { @@ -629,7 +629,7 @@ BankEditorDialog::updateDeviceItem(MidiDeviceListViewItem* deviceItem) bool BankEditorDialog::deviceItemHasBank(MidiDeviceListViewItem* deviceItem, int bankNb) { - QListViewItem *child = deviceItem->firstChild(); + TQListViewItem *child = deviceItem->firstChild(); while (child) { MidiBankListViewItem *bankItem = @@ -645,9 +645,9 @@ BankEditorDialog::deviceItemHasBank(MidiDeviceListViewItem* deviceItem, int bank } void -BankEditorDialog::clearItemChildren(QListViewItem* item) +BankEditorDialog::clearItemChildren(TQListViewItem* item) { - QListViewItem* child = 0; + TQListViewItem* child = 0; while ((child = item->firstChild())) delete child; @@ -719,7 +719,7 @@ BankEditorDialog::checkModified() } void -BankEditorDialog::slotPopulateDevice(QListViewItem* item) +BankEditorDialog::slotPopulateDevice(TQListViewItem* item) { RG_DEBUG << "BankEditorDialog::slotPopulateDevice" << endl; @@ -732,7 +732,7 @@ BankEditorDialog::slotPopulateDevice(QListViewItem* item) } void -BankEditorDialog::populateDevice(QListViewItem* item) +BankEditorDialog::populateDevice(TQListViewItem* item) { RG_DEBUG << "BankEditorDialog::populateDevice\n"; @@ -962,7 +962,7 @@ BankEditorDialog::slotUpdate() } MidiDeviceListViewItem* -BankEditorDialog::getParentDeviceItem(QListViewItem* item) +BankEditorDialog::getParentDeviceItem(TQListViewItem* item) { if (!item) return 0; @@ -989,7 +989,7 @@ BankEditorDialog::slotAddBank() if (!m_listView->currentItem()) return ; - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); MidiDeviceListViewItem* deviceItem = getParentDeviceItem(currentItem); MidiDevice *device = getMidiDevice(currentItem); @@ -1010,7 +1010,7 @@ BankEditorDialog::slotAddBank() qstrtostr(i18n("<new bank>"))); m_bankList.push_back(newBank); - QListViewItem* newBankItem = + TQListViewItem* newBankItem = new MidiBankListViewItem(deviceItem->getDeviceId(), m_bankList.size() - 1, deviceItem, @@ -1031,14 +1031,14 @@ BankEditorDialog::slotAddKeyMapping() if (!m_listView->currentItem()) return ; - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); MidiDeviceListViewItem* deviceItem = getParentDeviceItem(currentItem); MidiDevice *device = getMidiDevice(currentItem); if (device) { - QString name = ""; + TQString name = ""; int n = 0; while (name == "" || device->getKeyMappingByName(qstrtostr(name)) != 0) { ++n; @@ -1076,7 +1076,7 @@ BankEditorDialog::slotDelete() if (!m_listView->currentItem()) return ; - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); MidiBankListViewItem* bankItem = dynamic_cast<MidiBankListViewItem*>(currentItem); @@ -1180,19 +1180,19 @@ BankEditorDialog::slotDeleteAll() if (!m_listView->currentItem()) return ; - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); MidiDeviceListViewItem* deviceItem = getParentDeviceItem(currentItem); MidiDevice *device = getMidiDevice(deviceItem); - QString question = i18n("Really delete all banks for ") + - strtoqstr(device->getName()) + QString(" ?"); + TQString question = i18n("Really delete all banks for ") + + strtoqstr(device->getName()) + TQString(" ?"); int reply = KMessageBox::warningYesNo(this, question); if (reply == KMessageBox::Yes) { // erase all bank items - QListViewItem* child = 0; + TQListViewItem* child = 0; while ((child = deviceItem->firstChild())) delete child; @@ -1244,7 +1244,7 @@ BankEditorDialog::getMidiDevice(DeviceId id) } MidiDevice* -BankEditorDialog::getMidiDevice(QListViewItem* item) +BankEditorDialog::getMidiDevice(TQListViewItem* item) { MidiDeviceListViewItem* deviceItem = dynamic_cast<MidiDeviceListViewItem*>(item); @@ -1255,7 +1255,7 @@ BankEditorDialog::getMidiDevice(QListViewItem* item) } std::pair<int, int> -BankEditorDialog::getFirstFreeBank(QListViewItem* item) +BankEditorDialog::getFirstFreeBank(TQListViewItem* item) { //!!! percussion? this is actually only called in the expectation // that percussion==false at the moment @@ -1277,7 +1277,7 @@ BankEditorDialog::getFirstFreeBank(QListViewItem* item) } void -BankEditorDialog::slotModifyDeviceOrBankName(QListViewItem* item, const QString &label, int) +BankEditorDialog::slotModifyDeviceOrBankName(TQListViewItem* item, const TQString &label, int) { RG_DEBUG << "BankEditorDialog::slotModifyDeviceOrBankName" << endl; @@ -1305,9 +1305,9 @@ BankEditorDialog::slotModifyDeviceOrBankName(QListViewItem* item, const QString RG_DEBUG << "BankEditorDialog::slotModifyDeviceOrBankName - " << "modify key mapping name to " << label << endl; - QString oldName = keyItem->getName(); + TQString oldName = keyItem->getName(); - QListViewItem* currentItem = m_listView->currentItem(); + TQListViewItem* currentItem = m_listView->currentItem(); MidiDevice *device = getMidiDevice(currentItem); if (device) { @@ -1358,7 +1358,7 @@ BankEditorDialog::slotModifyDeviceOrBankName(QListViewItem* item, const QString void BankEditorDialog::selectDeviceItem(MidiDevice *device) { - QListViewItem *child = m_listView->firstChild(); + TQListViewItem *child = m_listView->firstChild(); MidiDeviceListViewItem *midiDeviceItem; MidiDevice *midiDevice; @@ -1381,8 +1381,8 @@ void BankEditorDialog::selectDeviceBankItem(DeviceId deviceId, int bank) { - QListViewItem *deviceChild = m_listView->firstChild(); - QListViewItem *bankChild; + TQListViewItem *deviceChild = m_listView->firstChild(); + TQListViewItem *bankChild; int deviceCount = 0, bankCount = 0; do { @@ -1462,8 +1462,8 @@ BankEditorDialog::getCommandHistory() void BankEditorDialog::slotImport() { - QString deviceDir = KGlobal::dirs()->findResource("appdata", "library/"); - QDir dir(deviceDir); + TQString deviceDir = KGlobal::dirs()->findResource("appdata", "library/"); + TQDir dir(deviceDir); if (!dir.exists()) { deviceDir = ":ROSEGARDENDEVICE"; } else { @@ -1479,7 +1479,7 @@ BankEditorDialog::slotImport() return ; ImportDeviceDialog *dialog = new ImportDeviceDialog(this, url); - if (dialog->doImport() && dialog->exec() == QDialog::Accepted) { + if (dialog->doImport() && dialog->exec() == TQDialog::Accepted) { MidiDeviceListViewItem* deviceItem = dynamic_cast<MidiDeviceListViewItem*> @@ -1614,11 +1614,11 @@ BankEditorDialog::slotEditPaste() void BankEditorDialog::slotExport() { - QString extension = "rgd"; + TQString extension = "rgd"; - QString name = + TQString name = KFileDialog::getSaveFileName(":ROSEGARDEN", - (extension.isEmpty() ? QString("*") : ("*." + extension)), + (extension.isEmpty() ? TQString("*") : ("*." + extension)), this, i18n("Export Device as...")); @@ -1634,7 +1634,7 @@ BankEditorDialog::slotExport() } } - QFileInfo info(name); + TQFileInfo info(name); if (info.isDir()) { KMessageBox::sorry(this, i18n("You have specified a directory")); @@ -1660,7 +1660,7 @@ BankEditorDialog::slotExport() if (md) { ExportDeviceDialog *ed = new ExportDeviceDialog (this, strtoqstr(md->getName())); - if (ed->exec() != QDialog::Accepted) + if (ed->exec() != TQDialog::Accepted) return ; if (ed->getExportType() == ExportDeviceDialog::ExportOne) { devices.push_back(md->getId()); @@ -1686,7 +1686,7 @@ BankEditorDialog::slotFileClose() } void -BankEditorDialog::closeEvent(QCloseEvent *e) +BankEditorDialog::closeEvent(TQCloseEvent *e) { if (m_modified) { |