diff options
| author | Carl Hetherington <cth@carlh.net> | 2023-01-28 10:18:18 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2023-02-11 22:26:38 +0100 |
| commit | 6ca8f63ff524330bf58877ffe963466495e46758 (patch) | |
| tree | f0b4a3f7c7f967b3fec380bf233d4fa685a52c04 | |
| parent | 5b69bcc581ecca47f10d6da6c6a8415b774afef0 (diff) | |
Use the correct prompt for file/folder.
| -rw-r--r-- | src/tools/dcpomatic_kdm.cc | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/tools/dcpomatic_kdm.cc b/src/tools/dcpomatic_kdm.cc index f0406c1d0..0d79d67a8 100644 --- a/src/tools/dcpomatic_kdm.cc +++ b/src/tools/dcpomatic_kdm.cc @@ -312,10 +312,17 @@ private: bool confirm_overwrite (boost::filesystem::path path) { - return confirm_dialog ( - this, - wxString::Format (_("File %s already exists. Do you want to overwrite it?"), std_to_wx(path.string()).data()) - ); + if (boost::filesystem::is_directory(path)) { + return confirm_dialog ( + this, + wxString::Format(_("Folder %s already exists. Do you want to overwrite it?"), std_to_wx(path.string()).data()) + ); + } else { + return confirm_dialog ( + this, + wxString::Format(_("File %s already exists. Do you want to overwrite it?"), std_to_wx(path.string()).data()) + ); + } } /** @id if not nullptr this is filled in with the wxTreeItemId of the selection */ |
