mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-30 03:28:41 -07:00
Avoid temporary QString allocations
This fixes clazy warning: Use multi-arg instead [-Wclazy-qstring-arg]
This commit is contained in:
parent
c60b7b213e
commit
0457fd260e
29 changed files with 137 additions and 123 deletions
|
@ -105,7 +105,8 @@ void ExecutionLog::addPeerMessage(const Log::Peer& peer)
|
|||
QDateTime time = QDateTime::fromMSecsSinceEpoch(peer.timestamp);
|
||||
|
||||
if (peer.blocked)
|
||||
text = "<font color='grey'>" + time.toString(Qt::SystemLocaleShortDate) + "</font> - " + tr("<font color='red'>%1</font> was blocked %2", "x.y.z.w was blocked").arg(peer.ip).arg(peer.reason);
|
||||
text = "<font color='grey'>" + time.toString(Qt::SystemLocaleShortDate) + "</font> - "
|
||||
+ tr("<font color='red'>%1</font> was blocked %2", "x.y.z.w was blocked").arg(peer.ip, peer.reason);
|
||||
else
|
||||
text = "<font color='grey'>" + time.toString(Qt::SystemLocaleShortDate) + "</font> - " + tr("<font color='red'>%1</font> was banned", "x.y.z.w was banned").arg(peer.ip);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue