Export failure tests limit only the panel's accept; margin measured (12.8d)

This commit is contained in:
雷电芽衣 committed 2026-09-27 21:24:07 -04:00
1 parent b544e12b1d
commit 9d012d325a
4 files changed
+27 -17

No files matched your search

+7 -1
View File
@@ -21,6 +21,8 @@ public:
std::function<QString()> note;
// Typed into a panel's name field before "<cancel>".
QString typeBeforeCancel;
// Wraps a panel's accept, as a memory limit might.
std::function<void(const std::function<void()> &)> aroundAccept;
DialogDesk()
{
@@ -89,7 +91,11 @@ private:
// Typed like a user; several files quoted, as panels read.
const QStringList paths = reply.split(QLatin1Char('|'));
name->setText(paths.size() == 1 ? reply : QStringLiteral("\"") + paths.join(QStringLiteral("\" \"")) + QStringLiteral("\""));
static_cast<QDialog *>(panel)->accept();
const auto accept = [panel] { static_cast<QDialog *>(panel)->accept(); };
if (aroundAccept)
aroundAccept(accept);
else
accept();
}
QTemporaryDir m_folder;