void CSVDoc::FileDialog::showDialog (ContentAction action) { mAction = action; ui.projectGroupBoxLayout->insertWidget (0, mAdjusterWidget); switch (mAction) { case ContentAction_New: buildNewFileView(); break; case ContentAction_Edit: buildOpenFileView(); break; default: break; } mAdjusterWidget->setFilenameCheck (mAction == ContentAction_New); if(!mDialogBuilt) { //connections common to both dialog view flavors connect (mSelector, SIGNAL (signalCurrentGamefileIndexChanged (int)), this, SLOT (slotUpdateAcceptButton (int))); connect (ui.projectButtonBox, SIGNAL (rejected()), this, SLOT (slotRejected())); mDialogBuilt = true; }
InitSettingsDialog::InitSettingsDialog(QWidget *parent) : QDialog(parent), ui(new Ui::InitSettingsDialog) { ui->setupUi(this); ui->lineEdit->setInputMask("99999"); QFontMetrics metrics(QApplication::font()); ui->lineEdit->setFixedSize(metrics.width("88888")+14,ui->lineEdit->height()+4); QMessageBox *infoBox = new QMessageBox(this); infoBox->setText("In order to use Weather Bee, you need to enter your zip code and choose a radar station."); infoBox->exec(); connect(ui->buttonBox, SIGNAL(rejected()), this, SLOT(slotRejected())); }
void AssignNameOverlay::setActive(bool active) { PersistentWidgetDelegateOverlay::setActive(active); if (active) { connect(assignNameWidget(), SIGNAL(assigned(TaggingAction,ImageInfo,QVariant)), this, SLOT(slotAssigned(TaggingAction,ImageInfo,QVariant))); connect(assignNameWidget(), SIGNAL(rejected(ImageInfo,QVariant)), this, SLOT(slotRejected(ImageInfo,QVariant))); connect(assignNameWidget(), SIGNAL(selected(TaggingAction,ImageInfo,QVariant)), this, SLOT(enterPersistentMode())); connect(assignNameWidget(), SIGNAL(assigned(TaggingAction,ImageInfo,QVariant)), this, SLOT(leavePersistentMode())); connect(assignNameWidget(), SIGNAL(rejected(ImageInfo,QVariant)), this, SLOT(leavePersistentMode())); connect(assignNameWidget(), SIGNAL(assigned(TaggingAction,ImageInfo,QVariant)), this, SLOT(storeFocus())); connect(assignNameWidget(), SIGNAL(rejected(ImageInfo,QVariant)), this, SLOT(storeFocus())); /* if (view()->model()) connect(view()->model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(slotDataChanged(QModelIndex,QModelIndex))); */ } else { // widget is deleted /* if (view() && view()->model()) disconnect(view()->model(), 0, this, 0); */ } }
RedefineDlg::RedefineDlg() { m_accountName.clear(); m_amountColumn = 0; m_columnTotalWidth = 0; m_maxWidth = 0; m_mainHeight = 0; m_mainWidth = 0; m_priceColumn = 0; m_quantityColumn = 0; m_ret = 0; m_typeColumn = 0; m_price = 0; m_quantity = 0; m_amount = 0; m_typesList << "buy" << "sell" << "divx" << "reinvdiv" << "shrsin" << "shrsout" << "intinc"; m_iconYes = QPixmap(KIconLoader::global()->loadIcon("dialog-ok", KIconLoader::Small, KIconLoader::DefaultState)); m_iconNo = QPixmap(KIconLoader::global()->loadIcon("dialog-cancel", KIconLoader::Small, KIconLoader::DefaultState)); m_widget = new RedefineDlgDecl(); setMainWidget(m_widget); m_widget->tableWidget->setToolTip(i18n("Results table")); m_widget->tableWidget->setRowCount(2); m_mainWidth = m_widget->tableWidget->size().width(); m_mainHeight = m_widget->tableWidget->size().height(); this->enableButtonOk(false); m_widget->kcombobox_Actions->setCurrentIndex(-1); connect(m_widget->kcombobox_Actions, SIGNAL(activated(int)), this, SLOT(slotNewActionSelected(int))); connect(this, SIGNAL(okClicked()), this, SLOT(slotAccepted())); connect(this, SIGNAL(cancelClicked()), this, SLOT(slotRejected())); }