Feed editings....

This commit is contained in:
Martin Rotter 2014-01-29 21:18:14 +01:00
parent 485968f738
commit daa1e1ab96
2 changed files with 15 additions and 0 deletions

View File

@ -73,12 +73,26 @@ void FormStandardFeedDetails::onDescriptionChanged(const QString &new_descriptio
}
}
void FormStandardFeedDetails::onUrlChanged(const QString &new_url) {
if (new_url.isEmpty()) {
// New url is well-formed.
}
else if (!new_url.simplified().isEmpty()) {
// New url is not well-formed but is not empty on the other hand.
}
else {
// New url is empty.
}
}
void FormStandardFeedDetails::createConnections() {
// General connections.
connect(m_ui->m_txtTitle->lineEdit(), SIGNAL(textChanged(QString)),
this, SLOT(onTitleChanged(QString)));
connect(m_ui->m_txtDescription->lineEdit(), SIGNAL(textChanged(QString)),
this, SLOT(onDescriptionChanged(QString)));
connect(m_ui->m_txtUrl->lineEdit(), SIGNAL(textChanged(QString)),
this, SLOT(onUrlChanged(QString)));
// Icon connections.
}

View File

@ -30,6 +30,7 @@ class FormStandardFeedDetails : public QDialog {
// Trigerred when title/description changes.
void onTitleChanged(const QString &new_title);
void onDescriptionChanged(const QString &new_description);
void onUrlChanged(const QString &new_url);
protected:
void createConnections();