| 40 | ImporterConfigDialog *q = nullptr; |
| 41 | |
| 42 | void setupHelpText() |
| 43 | { |
| 44 | QString helpText = QStringLiteral("<ul>"); |
| 45 | FileNameFormater::HelpMap map = FileNameFormater::helpMap(); |
| 46 | FileNameFormater::HelpMap::ConstIterator it = map.constBegin(), end = map.constEnd(); |
| 47 | for (; it != end; ++it) { |
| 48 | const QString keyword = QLatin1Char('{') + it.key() + QLatin1Char('}'); |
| 49 | const QString explanation = it.value().toHtmlEscaped(); |
| 50 | const QString link = QStringLiteral("<a href='%1'>%1</a>").arg(keyword); |
| 51 | helpText += |
| 52 | QLatin1String("<li>") + i18nc("%1 is the importer keyword, %2 is keyword explanation", "%1: %2", link, explanation) + QLatin1String("</li>"); |
| 53 | } |
| 54 | helpText += QLatin1String("</ul>"); |
| 55 | mRenameFormatHelpLabel->setText(helpText); |
| 56 | |
| 57 | QObject::connect(mRenameFormatHelpLabel, SIGNAL(linkActivated(QString)), q, SLOT(slotHelpLinkActivated(QString))); |
| 58 | } |
| 59 | }; |
| 60 | |
| 61 | ImporterConfigDialog::ImporterConfigDialog(QWidget *parent) |
no test coverage detected