|
|
|
|
@ -642,8 +642,9 @@ void MemberFileBrowser::mutate(uint8_t command) {
|
|
|
|
|
auto entries = selectedEntries(); if (entries.isEmpty()) return; |
|
|
|
|
QPointer<MemberFileBrowser> guard(this); |
|
|
|
|
m_dropId = requestId(); updateActions(); |
|
|
|
|
QString prompt = entries.size() == 1 ? text("Delete %1?").arg(entries.first().remote) : |
|
|
|
|
text("Delete %1 selected entries? Non-empty folders will not be removed.").arg(entries.size()); |
|
|
|
|
QString prompt = entries.size() == 1 |
|
|
|
|
? (entries.first().directory ? text("Delete %1 and all its contents?") : text("Delete %1?")).arg(entries.first().remote) |
|
|
|
|
: text("Delete %1 selected entries and all folder contents?").arg(entries.size()); |
|
|
|
|
auto answer = QMessageBox::question(this, text("Delete"), prompt, QMessageBox::Yes | QMessageBox::No, QMessageBox::No); |
|
|
|
|
if (!guard) return; |
|
|
|
|
bool cancelled = !m_dropId; m_dropId = 0; updateActions(); |
|
|
|
|
|