void GalleryWindow::connectSignals() { connect(d->albumView, SIGNAL(itemSelectionChanged()), this , SLOT(slotAlbumSelected()) ); connect(d->newAlbumBtn, SIGNAL(clicked()), this, SLOT(slotNewAlbum())); connect(d->addPhotoBtn, SIGNAL(clicked()), this, SLOT(slotAddPhoto())); connect(d->resizeCheckBox, SIGNAL(stateChanged(int)), this, SLOT(slotEnableSpinBox(int))); connect(d->logo, SIGNAL(leftClickedUrl(QString)), this, SLOT(slotProcessUrl(QString))); connect(m_progressDlg, SIGNAL(canceled()), this, SLOT(slotAddPhotoCancel())); connect(m_talker, SIGNAL(signalError(QString)), this, SLOT(slotError(QString))); connect(m_talker, SIGNAL(signalBusy(bool)), this, SLOT(slotBusy(bool))); connect(m_talker, SIGNAL(signalLoginFailed(QString)), this, SLOT(slotLoginFailed(QString))); connect(m_talker, SIGNAL(signalAlbums(QList<GAlbum>)), this, SLOT(slotAlbums(QList<GAlbum>))); connect(m_talker, SIGNAL(signalPhotos(QList<GPhoto>)), this, SLOT(slotPhotos(QList<GPhoto>))); connect(m_talker, SIGNAL(signalAddPhotoSucceeded()), this, SLOT(slotAddPhotoSucceeded())); connect(m_talker, SIGNAL(signalAddPhotoFailed(QString)), this, SLOT(slotAddPhotoFailed(QString))); }
TemplateViewer::TemplateViewer(QWidget* const parent) : RExpanderBox(parent), d(new Private) { setFrameStyle(QFrame::NoFrame); KVBox* w1 = new KVBox(this); d->names = new DTextLabelName(i18n("Names:"), w1); d->namesList = new DTextList(QStringList(), w1); d->position = new DTextLabelName(i18n("Position:"), w1); d->labelPosition = new DTextBrowser(QString(), w1); d->credit = new DTextLabelName(i18n("Credit:"), w1); d->labelCredit = new DTextBrowser(QString(), w1); d->copyright = new DTextLabelName(i18n("Copyright:"), w1); d->labelCopyright = new DTextBrowser(QString(), w1); d->usages = new DTextLabelName(i18n("Usages:"), w1); d->labelUsages = new DTextBrowser(QString(), w1); d->source = new DTextLabelName(i18n("Source:"), w1); d->labelSource = new DTextBrowser(QString(), w1); d->instructions = new DTextLabelName(i18n("Instructions:"), w1); d->labelInstructions = new DTextBrowser(QString(), w1); d->names->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->position->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->credit->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->copyright->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->credit->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->usages->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->source->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->instructions->setAlignment(Qt::AlignLeft | Qt::AlignTop); addItem(w1, SmallIcon("flag-red"), i18n("Rights"), QString("Rights"), true); // ------------------------------------------------------------------ KVBox* w2 = new KVBox(this); d->locationCity = new DTextLabelName(i18n("City:"), w2); d->labelLocationCity = new DTextBrowser(QString(), w2); d->locationSublocation = new DTextLabelName(i18n("Sublocation:"), w2); d->labelLocationSublocation = new DTextBrowser(QString(), w2); d->locationProvinceState = new DTextLabelName(i18n("Province/State:"), w2); d->labelLocationProvinceState = new DTextBrowser(QString(), w2); d->locationCountry = new DTextLabelName(i18n("Country:"), w2); d->labelLocationCountry = new DTextBrowser(QString(), w2); d->locationCity->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->locationSublocation->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->locationProvinceState->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->locationCountry->setAlignment(Qt::AlignLeft | Qt::AlignTop); addItem(w2, SmallIcon("applications-internet"), i18n("Location"), QString("Location"), true); // ------------------------------------------------------------------ KVBox* w3 = new KVBox(this); d->contactAddress = new DTextLabelName(i18n("Address:"), w3); d->labelContactAddress = new DTextBrowser(QString(), w3); d->contactPostalCode = new DTextLabelName(i18n("Postal Code:"), w3); d->labelContactPostalCode = new DTextBrowser(QString(), w3); d->contactCity = new DTextLabelName(i18n("City:"), w3); d->labelContactCity = new DTextBrowser(QString(), w3); d->contactProvinceState = new DTextLabelName(i18n("Province/State:"), w3); d->labelContactProvinceState = new DTextBrowser(QString(), w3); d->contactCountry = new DTextLabelName(i18n("Country:"), w3); d->labelContactCountry = new DTextBrowser(QString(), w3); d->contactPhone = new DTextLabelName(i18n("Phone:"), w3); d->labelContactPhone = new DTextBrowser(QString(), w3); d->contactEmail = new DTextLabelName(i18n("Email:"), w3); d->labelContactEmail = new KUrlLabel(w3); d->contactWebUrl = new DTextLabelName(i18n("URL:"), w3); d->labelContactWebUrl = new KUrlLabel(w3); d->contactAddress->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactPostalCode->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactCity->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactProvinceState->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactCountry->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactPhone->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactEmail->setAlignment(Qt::AlignLeft | Qt::AlignTop); d->contactWebUrl->setAlignment(Qt::AlignLeft | Qt::AlignTop); addItem(w3, SmallIcon("view-pim-contacts"), i18n("Contact"), QString("Contact"), true); // ------------------------------------------------------------------ KVBox* w4 = new KVBox(this); d->subjectsList = new DTextList(QStringList(), w4); addItem(w4, SmallIcon("feed-subscribe"), i18n("Subjects"), QString("Subjects"), true); addStretch(); connect(d->labelContactWebUrl, SIGNAL(leftClickedUrl(QString)), this, SLOT(slotProcessUrl(QString))); connect(d->labelContactEmail, SIGNAL(leftClickedUrl(QString)), this, SLOT(slotProcessEmail(QString))); }