mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
QFileDialog::getOpenFileName returns an empty string on cancel (#4762)
There's no need to throw a message box up
This commit is contained in:
@@ -145,9 +145,9 @@ void CloudDBAcceptConditionsDialog::rejectConditions() {
|
||||
|
||||
// Initialize static members of CloudDBCommon
|
||||
|
||||
QString CloudDBCommon::cloudDBBaseURL = QString("https://%1.appspot.com/v1/").arg(GC_CLOUD_DB_APP_NAME);
|
||||
QString CloudDBCommon::cloudDBBaseURL = QString("https://%1.appspot.com/v1/").arg(QT_STRINGIFY(GC_CLOUD_DB_APP_NAME));
|
||||
QVariant CloudDBCommon::cloudDBContentType = QVariant("application/json");
|
||||
QByteArray CloudDBCommon::cloudDBBasicAuth = "Basic " + QByteArray(GC_CLOUD_DB_BASIC_AUTH) ;
|
||||
QByteArray CloudDBCommon::cloudDBBasicAuth = "Basic " + QByteArray(QT_STRINGIFY(GC_CLOUD_DB_BASIC_AUTH));
|
||||
|
||||
QList<QString> CloudDBCommon::cloudDBLangsIds = QList<QString>() << "en" << "fr" << "ja" << "pt-br" << "it" << "de" << "ru" << "cs" << "es" << "pt" << "zh-cn" << "zh-tw" << "nl" << "sv" << "xx";
|
||||
|
||||
|
||||
@@ -893,9 +893,7 @@ MainWindow::importChart()
|
||||
{
|
||||
QString fileName = QFileDialog::getOpenFileName(this, tr("Select Chart file to import"), "", tr("GoldenCheetah Chart Files (*.gchart)"));
|
||||
|
||||
if (fileName.isEmpty()) {
|
||||
QMessageBox::critical(this, tr("Import Chart"), tr("No chart file selected!"));
|
||||
} else {
|
||||
if (!fileName.isEmpty()) {
|
||||
importCharts(QStringList()<<fileName);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user