mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-27 11:49:01 +03:00
TorrentCreator: add .torrent extension only when missing
This commit is contained in:
parent
72f4c81f4c
commit
eb94c59892
1 changed files with 2 additions and 1 deletions
|
@ -191,7 +191,8 @@ void createtorrent::on_createButton_clicked(){
|
|||
QString destination = QFileDialog::getSaveFileName(this, tr("Select destination torrent file"), last_path, tr("Torrent Files")+QString::fromUtf8(" (*.torrent)"));
|
||||
if(!destination.isEmpty()) {
|
||||
settings.setValue("CreateTorrent/last_save_path", misc::removeLastPathPart(destination));
|
||||
destination += QString::fromUtf8(".torrent");
|
||||
if(!destination.toUpper().endsWith(".TORRENT"))
|
||||
destination += QString::fromUtf8(".torrent");
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue