Esempio n. 1
0
KChooseImportExportDlg::KChooseImportExportDlg(int type, QWidget *parent)
    : QDialog(parent), d(new Private)
{
  d->ui.setupUi(this);

  QString filename;
  setModal(true);

  if (type == 0) { // import
    d->ui.topLabel->setText(i18n("Please choose the type of import you wish to perform.  A simple explanation\n"
                                 "of the import type is available at the bottom of the screen and is updated when\n"
                                 "you select an item from the choice box."
                                 "\n\nOnce you have chosen an import type please press the OK button."));
    d->ui.promptLabel->setText(i18n("Choose import type:"));
    setWindowTitle(i18n("Choose Import Type Dialog"));
  } else { // export
    d->ui.topLabel->setText(i18n("Please choose the type of export you wish to perform.  A simple explanation\n"
                                 "of the export type is available at the bottom of the screen and is updated when\n"
                                 "you select an item from the choice box."
                                 "\n\nOnce you have chosen an export type please press the OK button."));
    d->ui.promptLabel->setText(i18n("Choose export type:"));
    setWindowTitle(i18n("Choose Export Type Dialog"));
  }

  readConfig();
  slotTypeActivated(m_lastType);
  d->ui.typeCombo->setCurrentItem(((m_lastType == "QIF") ? i18n("QIF") : i18n("CSV")), false);

  connect(d->ui.typeCombo, SIGNAL(activated(QString)), this, SLOT(slotTypeActivated(QString)));
  connect(d->ui.buttonBox, SIGNAL(accepted()), this, SLOT(accept()));
  connect(d->ui.buttonBox, SIGNAL(rejected()), this, SLOT(reject()));
}
Esempio n. 2
0
int QLCFixtureEditor::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QWidget::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        switch (_id) {
        case 0: slotManufacturerTextEdited((*reinterpret_cast< const QString(*)>(_a[1]))); break;
        case 1: slotModelTextEdited((*reinterpret_cast< const QString(*)>(_a[1]))); break;
        case 2: slotTypeActivated((*reinterpret_cast< const QString(*)>(_a[1]))); break;
        case 3: slotChannelListSelectionChanged((*reinterpret_cast< QTreeWidgetItem*(*)>(_a[1]))); break;
        case 4: slotAddChannel(); break;
        case 5: slotRemoveChannel(); break;
        case 6: slotEditChannel(); break;
        case 7: slotCopyChannel(); break;
        case 8: slotPasteChannel(); break;
        case 9: slotExpandChannels(); break;
        case 10: slotChannelListContextMenuRequested(); break;
        case 11: slotModeListSelectionChanged((*reinterpret_cast< QTreeWidgetItem*(*)>(_a[1]))); break;
        case 12: slotAddMode(); break;
        case 13: slotRemoveMode(); break;
        case 14: slotEditMode(); break;
        case 15: slotCloneMode(); break;
        case 16: slotExpandModes(); break;
        case 17: slotModeListContextMenuRequested(); break;
        case 18: slotClipboardChanged(); break;
        default: ;
        }
        _id -= 19;
    }
    return _id;
}
KChooseImportExportDlg::KChooseImportExportDlg(int type, QWidget *parent, const char *name )
 : KChooseImportExportDlgDecl(parent,name, true)
{
  QString filename;

  if (type==0) { // import
    topLabel->setText(i18n("Please choose the type of import you wish to perform.  A simple explanation\n"
        "of the import type is available at the bottom of the screen and is updated when\n"
        "you select an item from the choice box."
        "\n\nOnce you have chosen an import type please press the OK button." ));
    promptLabel->setText(i18n("Choose import type:"));
    setCaption(i18n("Choose Import Type Dialog"));
  } else { // export
    topLabel->setText(i18n("Please choose the type of export you wish to perform.  A simple explanation\n"
        "of the export type is available at the bottom of the screen and is updated when\n"
        "you select an item from the choice box."
        "\n\nOnce you have chosen an export type please press the OK button." ));
    promptLabel->setText(i18n("Choose export type:"));
    setCaption(i18n("Choose Export Type Dialog"));
  }

  readConfig();
  slotTypeActivated(m_lastType);
  typeCombo->setCurrentItem(((m_lastType=="QIF") ? 0 : 1));

  connect(typeCombo, SIGNAL(activated(const QString&)), this, SLOT(slotTypeActivated(const QString&)));
  connect(okButton, SIGNAL(clicked()), this, SLOT(accept()));
  connect(cancelButton, SIGNAL(clicked()), this, SLOT(reject()));
}
Esempio n. 4
0
int InputChannelEditor::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QDialog::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        switch (_id) {
        case 0: slotNumberChanged((*reinterpret_cast< int(*)>(_a[1]))); break;
        case 1: slotNameEdited((*reinterpret_cast< const QString(*)>(_a[1]))); break;
        case 2: slotTypeActivated((*reinterpret_cast< const QString(*)>(_a[1]))); break;
        default: ;
        }
        _id -= 3;
    }
    return _id;
}