|
|
@ -340,7 +340,13 @@ UBYouTubePublishingDialog::UBYouTubePublishingDialog(const QString& videoFilePat |
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setEnabled(false); |
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setEnabled(false); |
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setText(tr("Upload")); |
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setText(tr("Upload")); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
UBSettings* settings = UBSettings::settings(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
email->setText(settings->youTubeUserEMail->get().toString()); |
|
|
|
|
|
|
|
password->setText(settings->password(email->text())); |
|
|
|
|
|
|
|
|
|
|
|
youtubeCredentialsPersistence->setChecked(UBSettings::settings()->youTubeCredentialsPersistence->get().toBool()); |
|
|
|
youtubeCredentialsPersistence->setChecked(UBSettings::settings()->youTubeCredentialsPersistence->get().toBool()); |
|
|
|
|
|
|
|
updatePersistanceEnableState(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -353,7 +359,7 @@ void UBYouTubePublishingDialog::updatePersistanceEnableState() |
|
|
|
{ |
|
|
|
{ |
|
|
|
bool enabled = email->text().length() || password->text().length(); |
|
|
|
bool enabled = email->text().length() || password->text().length(); |
|
|
|
youtubeCredentialsPersistence->setEnabled(enabled); |
|
|
|
youtubeCredentialsPersistence->setEnabled(enabled); |
|
|
|
youtubeCredentialsPersistence->setStyleSheet(enabled ? "color:black;" : "color lightgray;"); |
|
|
|
youtubeCredentialsPersistence->setStyleSheet(enabled ? "color:black;" : "color : lightgrey;"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void UBYouTubePublishingDialog::updateUIState(const QString& string) |
|
|
|
void UBYouTubePublishingDialog::updateUIState(const QString& string) |
|
|
@ -367,6 +373,7 @@ void UBYouTubePublishingDialog::updateUIState(const QString& string) |
|
|
|
&& password->text().length() > 0; |
|
|
|
&& password->text().length() > 0; |
|
|
|
|
|
|
|
|
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setEnabled(ok); |
|
|
|
dialogButtons->button(QDialogButtonBox::Ok)->setEnabled(ok); |
|
|
|
|
|
|
|
updatePersistanceEnableState(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|