Commit 6a561d94 authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

Fix capitalization of "Pastebin.Com".



Task-number: QTCREATORBUG-9997

Change-Id: Ib9366aa49f4e7b83d76a05741f12afbac159013a
Reviewed-by: default avatarRobert Loehning <robert.loehning@digia.com>
parent 799bd460
......@@ -48,6 +48,8 @@ static const char PASTEBIN_ARCHIVE[]="archive";
static const char API_KEY[]="api_dev_key=516686fc461fb7f9341fd7cf2af6f829&"; // user: qtcreator_apikey
static const char PROTOCOL_NAME[] = "Pastebin.Com";
namespace CodePaster {
PasteBinDotComProtocol::PasteBinDotComProtocol() :
m_fetchReply(0),
......@@ -61,7 +63,7 @@ PasteBinDotComProtocol::PasteBinDotComProtocol() :
QString PasteBinDotComProtocol::protocolName()
{
return QLatin1String("Pastebin.Com");
return QLatin1String(PROTOCOL_NAME);
}
unsigned PasteBinDotComProtocol::capabilities() const
......@@ -141,7 +143,7 @@ void PasteBinDotComProtocol::paste(const QString &text,
void PasteBinDotComProtocol::pasteFinished()
{
if (m_pasteReply->error())
qWarning("Pastebin.com protocol error: %s", qPrintable(m_pasteReply->errorString()));
qWarning("%s protocol error: %s", PROTOCOL_NAME, qPrintable(m_pasteReply->errorString()));
else
emit pasteDone(QString::fromLatin1(m_pasteReply->readAll()));
......@@ -178,7 +180,7 @@ void PasteBinDotComProtocol::fetchFinished()
if (debug)
qDebug() << "fetchFinished: error" << m_fetchId << content;
} else {
title = QString::fromLatin1("Pastebin.com: %1").arg(m_fetchId);
title = QLatin1String(PROTOCOL_NAME) + QLatin1String(": ") + m_fetchId;
content = QString::fromLatin1(m_fetchReply->readAll());
// Cut out from '<pre>' formatting
const int preEnd = content.lastIndexOf(QLatin1String("</pre>"));
......
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