+ fix branding bug, use tr() function of class not QObject
This commit is contained in:
parent
4efaacc5b3
commit
2dd871389e
|
@ -38,6 +38,8 @@
|
||||||
|
|
||||||
using namespace Gui;
|
using namespace Gui;
|
||||||
|
|
||||||
|
/* TRANSLATOR Gui::Assistant */
|
||||||
|
|
||||||
Assistant::Assistant()
|
Assistant::Assistant()
|
||||||
: proc(0)
|
: proc(0)
|
||||||
{
|
{
|
||||||
|
@ -100,8 +102,8 @@ bool Assistant::startAssistant()
|
||||||
|
|
||||||
Base::FileInfo fi ( (const char*)qhc.toUtf8() );
|
Base::FileInfo fi ( (const char*)qhc.toUtf8() );
|
||||||
if (!fi.isReadable()) {
|
if (!fi.isReadable()) {
|
||||||
QMessageBox::critical(0, QObject::tr("%1 Help").arg(exe),
|
QMessageBox::critical(0, tr("%1 Help").arg(exe),
|
||||||
QObject::tr("FreeCAD help files not found (%1). You might need to install the FreeCAD documentation package.").arg(qhc));
|
tr("%1 help files not found (%2). You might need to install the %1 documentation package.").arg(exe).arg(qhc));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -110,7 +112,7 @@ bool Assistant::startAssistant()
|
||||||
Base::Console().Log("Help file at %s\n", (const char*)qhc.toUtf8());
|
Base::Console().Log("Help file at %s\n", (const char*)qhc.toUtf8());
|
||||||
first = false;
|
first = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
QStringList args;
|
QStringList args;
|
||||||
|
|
||||||
args << QLatin1String("-collectionFile") << qhc
|
args << QLatin1String("-collectionFile") << qhc
|
||||||
|
@ -119,8 +121,8 @@ bool Assistant::startAssistant()
|
||||||
proc->start(app, args);
|
proc->start(app, args);
|
||||||
|
|
||||||
if (!proc->waitForStarted()) {
|
if (!proc->waitForStarted()) {
|
||||||
QMessageBox::critical(0, QObject::tr("%1 Help").arg(exe),
|
QMessageBox::critical(0, tr("%1 Help").arg(exe),
|
||||||
QObject::tr("Unable to launch Qt Assistant (%1)").arg(app));
|
tr("Unable to launch Qt Assistant (%1)").arg(app));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user