code cleanup: remove allocations

Simply create the string in one go.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Tomaz Canabrava 2018-09-15 08:26:35 -07:00 committed by Dirk Hohndel
parent 2d6633eee0
commit 9e6a3bee0d

View file

@ -1342,26 +1342,25 @@ void MainWindow::on_actionHash_images_triggered()
QString MainWindow::filter_open()
{
QString f;
f += tr("Dive log files");
f += " (*.ssrf";
f += " *.xml";
f += " *.can";
f += " *.db" ;
f += " *.sql" ;
f += " *.dld";
f += " *.jlb";
f += " *.lvd";
f += " *.sde";
f += " *.udcf";
f += " *.uddf";
f += " *.dlf";
f += " *.log";
f += " *.txt";
f += " *.apd";
f += " *.dive";
f += " *.zxu *.zxl";
f += ");;";
QString f = tr("Dive log files") +
" (*.ssrf"
" *.xml"
" *.can"
" *.db"
" *.sql"
" *.dld"
" *.jlb"
" *.lvd"
" *.sde"
" *.udcf"
" *.uddf"
" *.dlf"
" *.log"
" *.txt"
" *.apd"
" *.dive"
" *.zxu *.zxl"
");;";
f += tr("Subsurface files") + " (*.ssrf *.xml);;";
f += tr("Cochran") + " (*.can);;";
@ -1384,27 +1383,26 @@ QString MainWindow::filter_open()
QString MainWindow::filter_import()
{
QString f;
f += tr("Dive log files");
f += " (*.ssrf";
f += " *.xml";
f += " *.can";
f += " *.csv";
f += " *.db" ;
f += " *.sql" ;
f += " *.dld";
f += " *.jlb";
f += " *.lvd";
f += " *.sde";
f += " *.udcf";
f += " *.uddf";
f += " *.dlf";
f += " *.log";
f += " *.txt";
f += " *.apd";
f += " *.dive";
f += " *.zxu *.zxl";
f += ");;";
QString f = tr("Dive log files") +
" (*.ssrf"
" *.xml"
" *.can"
" *.csv"
" *.db"
" *.sql"
" *.dld"
" *.jlb"
" *.lvd"
" *.sde"
" *.udcf"
" *.uddf"
" *.dlf"
" *.log"
" *.txt"
" *.apd"
" *.dive"
" *.zxu *.zxl"
");;";
f += tr("Subsurface files") + " (*.ssrf *.xml);;";
f += tr("Cochran") + " (*.can);;";