mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-08 06:00:59 -07:00
Use QString literals
The plan is to define `QT_NO_CAST_FROM_ASCII` eventually. PR #16561.
This commit is contained in:
parent
2c8447853b
commit
ab64ee872b
23 changed files with 104 additions and 108 deletions
|
@ -116,7 +116,7 @@ namespace
|
|||
bool isTorrentLink(const QString &str)
|
||||
{
|
||||
return str.startsWith(QLatin1String("magnet:"), Qt::CaseInsensitive)
|
||||
|| str.endsWith(QLatin1String(C_TORRENT_FILE_EXTENSION), Qt::CaseInsensitive)
|
||||
|| str.endsWith(TORRENT_FILE_EXTENSION, Qt::CaseInsensitive)
|
||||
|| (!str.startsWith(QLatin1String("file:"), Qt::CaseInsensitive)
|
||||
&& Net::DownloadManager::hasSupportedScheme(str));
|
||||
}
|
||||
|
@ -1421,7 +1421,7 @@ void MainWindow::on_actionOpen_triggered()
|
|||
// Note: it is possible to select more than one file
|
||||
const QStringList pathsList =
|
||||
QFileDialog::getOpenFileNames(this, tr("Open Torrent Files"), pref->getMainLastDir().data(),
|
||||
tr("Torrent Files") + " (*" + C_TORRENT_FILE_EXTENSION + ')');
|
||||
tr("Torrent Files") + u" (*" + TORRENT_FILE_EXTENSION + u')');
|
||||
|
||||
if (pathsList.isEmpty())
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue