Replace single-character string with character literal

Also remove unnecessary dynamic allocation.
This commit is contained in:
Chocobo1 2018-07-21 13:28:13 +08:00
commit 0217d5b4c0
No known key found for this signature in database
GPG key ID: 210D9C873253A68C
32 changed files with 96 additions and 96 deletions

View file

@ -70,7 +70,7 @@ public:
QStyleOptionProgressBar newopt;
qreal progress = index.data().toDouble() * 100.;
newopt.rect = opt.rect;
newopt.text = ((progress == 100.0) ? QString("100%") : Utils::String::fromDouble(progress, 1) + "%");
newopt.text = ((progress == 100.0) ? QString("100%") : Utils::String::fromDouble(progress, 1) + '%');
newopt.progress = static_cast<int>(progress);
newopt.maximum = 100;
newopt.minimum = 0;