Commit ec5b1759 authored by Michael Georg Hansen's avatar Michael Georg Hansen
Browse files

Fix krazy2 issues: single-char QString.

parent 896a098b
......@@ -413,7 +413,7 @@ void ActionThread::run()
KExiv2 meta;
meta.load(t->urls[0].toLocalFile());
meta.setXmpTagString("Xmp.kipi.EnfuseInputFiles", t->enfuseSettings.inputImagesList(), false);
meta.setXmpTagString("Xmp.kipi.EnfuseSettings", t->enfuseSettings.asCommentString().replace("\n", " ; "), false);
meta.setXmpTagString("Xmp.kipi.EnfuseSettings", t->enfuseSettings.asCommentString().replace('\n', " ; "), false);
meta.setImageDateTime(QDateTime::currentDateTime());
if (t->enfuseSettings.outputFormat != SaveSettingsWidget::OUTPUT_JPEG)
{
......@@ -616,7 +616,7 @@ bool ActionThread::computePreview(const KUrl& inUrl, KUrl& outUrl)
{
outUrl = d->preprocessingTmpDir->name();
QFileInfo fi(inUrl.toLocalFile());
outUrl.setFileName(QString(".") + fi.completeBaseName().replace(".", "_") + QString("-preview.jpg"));
outUrl.setFileName(QString(".") + fi.completeBaseName().replace('.', '_') + QString("-preview.jpg"));
QImage img;
if (img.load(inUrl.toLocalFile()))
......@@ -689,7 +689,7 @@ bool ActionThread::convertRaw(const KUrl& inUrl, KUrl& outUrl, const RawDecoding
wImageIface.setImageData(imageData, width, height, true, false, prof, meta);
outUrl = d->preprocessingTmpDir->name();
QFileInfo fi(inUrl.toLocalFile());
outUrl.setFileName(QString(".") + fi.completeBaseName().replace(".", "_") + QString(".tif"));
outUrl.setFileName(QString(".") + fi.completeBaseName().replace('.', '_') + QString(".tif"));
if (!wImageIface.write2TIFF(outUrl.toLocalFile()))
return false;
......
......@@ -60,7 +60,7 @@ void AlignBinary::checkSystem()
if (firstLine.startsWith(headerStarts))
{
m_version = firstLine.remove(0, headerStarts.length()).section(".", 0, 1);
m_version = firstLine.remove(0, headerStarts.length()).section('.', 0, 1);
m_version.remove("Pre-Release "); // Special case with Hugin beta.
kDebug() << "Found " << path() << " version: " << version() ;
......
......@@ -65,13 +65,13 @@ void EnfuseBinary::checkSystem()
headerStarts = QString("enfuse ");
firstLine = findHeader(stdOut.split('\n', QString::SkipEmptyParts), headerStarts);
kDebug() << path() << " help header line: \n" << firstLine;
m_version = firstLine.remove(0, headerStarts.length()).section("-", 0, 0);
m_version = firstLine.remove(0, headerStarts.length()).section('-', 0, 0);
kDebug() << "Found " << path() << " version: " << version();
}
else
{
kDebug() << path() << " help header line: \n" << firstLine;
m_version = firstLine.remove(0, headerStarts.length()).section(" ", 0, 0);
m_version = firstLine.remove(0, headerStarts.length()).section(' ', 0, 0);
kDebug() << "Found " << path() << " version: " << version();
}
}
......
......@@ -285,11 +285,11 @@ void FbTalker::doOAuth()
url = KUrl( textbox->text() );
QString fragment = url.fragment();
kDebug() << "Split out the fragment from the URL: " << fragment;
QStringList params = fragment.split("&");
QStringList params = fragment.split('&');
QList<QString>::iterator i = params.begin();
while( i != params.end() )
{
QStringList keyvalue = (*i).split("=");
QStringList keyvalue = (*i).split('=');
if( keyvalue.size() == 2 )
{
if( ! keyvalue[0].compare( "access_token" ) )
......
......@@ -105,7 +105,7 @@ void WikiMediaJob::uploadHandle(KJob* j)
e1->setFile(file);
m_currentFile=file->fileName();
kDebug() << "image name : " << file->fileName().split("/").last();
kDebug() << "image name : " << file->fileName().split('/').last();
e1->setFilename(file->fileName());
e1->setText(buildWikiText(info));
......
......@@ -398,7 +398,7 @@ bool PicasawebTalker::addPhoto(const QString& photoPath, PicasaWebPhoto& info,
whereElem.appendChild(pointElem);
QDomElement gpsElem = docMeta.createElementNS("http://www.opengis.net/gml", "gml:pos");
pointElem.appendChild(gpsElem);
QDomText gpsVal = docMeta.createTextNode(info.gpsLat + " " + info.gpsLon);
QDomText gpsVal = docMeta.createTextNode(info.gpsLat + ' ' + info.gpsLon);
gpsElem.appendChild(gpsVal);
}
......@@ -472,7 +472,7 @@ bool PicasawebTalker::updatePhoto(const QString& photoPath, PicasaWebPhoto& info
whereElem.appendChild(pointElem);
QDomElement gpsElem = docMeta.createElementNS("http://www.opengis.net/gml", "gml:pos");
pointElem.appendChild(gpsElem);
QDomText gpsVal = docMeta.createTextNode(info.gpsLat + " " + info.gpsLon);
QDomText gpsVal = docMeta.createTextNode(info.gpsLat + ' ' + info.gpsLon);
gpsElem.appendChild(gpsVal);
}
......@@ -827,7 +827,7 @@ void PicasawebTalker::parseResponseListPhotos(const QByteArray& data)
QDomNode geoPosNode = geoPointNode.toElement().namedItem("gml:pos");
if (!geoPosNode.isNull() && geoPosNode.isElement())
{
QStringList value = geoPosNode.toElement().text().split(" ");
QStringList value = geoPosNode.toElement().text().split(' ');
if (value.size() == 2)
{
fps.gpsLat = value[0];
......@@ -847,7 +847,7 @@ void PicasawebTalker::parseResponseListPhotos(const QByteArray& data)
QDomNode keywordNode = detailsElem.namedItem("media:keywords");
if (!keywordNode.isNull() && keywordNode.isElement())
{
fps.tags = keywordNode.toElement().text().split(",");
fps.tags = keywordNode.toElement().text().split(',');
}
QDomNodeList contentsList = detailsElem.elementsByTagName("media:content");
......
......@@ -705,7 +705,7 @@ void PicasawebWindow::uploadNextPhoto()
QStringList::const_iterator itT;
for(itT = info.tags.constBegin(); itT != info.tags.constEnd(); ++itT)
{
QStringList strListTmp = itT->split("/");
QStringList strListTmp = itT->split('/');
QStringList::const_iterator itT2;
for(itT2 = strListTmp.constBegin(); itT2 != strListTmp.constEnd(); ++itT2)
{
......
......@@ -611,7 +611,7 @@ QString AddPhotoCommand::additionalXml() const
metadata["PerceivedType"] = "image"; //what are the other values here? video?
metadata["OriginalWidth"] = QString::number(m_image.width());
metadata["OriginalHeight"] = QString::number(m_image.height());
metadata["LengthMS"] = "0";
metadata["LengthMS"] = '0';
metadata["FileSize"] = QString::number(f.size());
//TODO extract these from exif
......
......@@ -140,7 +140,7 @@ QString MyImageListViewItem::identity() const
QString MyImageListViewItem::destPath() const
{
QString path = url().directory() + "/" + destFileName();
QString path = url().directory() + '/' + destFileName();
return path;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment