mirror of
https://bitbucket.org/smil3y/kde-extraapps.git
synced 2025-02-23 18:32:53 +00:00
kdeplasma-addons: converter runner string correction
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
ddead8b99f
commit
a4043a10b0
3 changed files with 4 additions and 4 deletions
|
@ -77,7 +77,6 @@ void QalculateEngine::evaluate(const QString& expression)
|
|||
|
||||
QString input = expression;
|
||||
QByteArray ba = input.replace(QChar(0xA3), "GBP").replace(QChar(0xA5), "JPY").replace('$', "USD").replace(QChar(0x20AC), "EUR").toLatin1();
|
||||
const char *ctext = ba.data();
|
||||
|
||||
EvaluationOptions eo;
|
||||
|
||||
|
@ -115,7 +114,7 @@ void QalculateEngine::evaluate(const QString& expression)
|
|||
break;
|
||||
}
|
||||
|
||||
MathStructure result = CALCULATOR->calculate(ctext, eo);
|
||||
MathStructure result = CALCULATOR->calculate(ba.constData(), eo);
|
||||
|
||||
PrintOptions po;
|
||||
switch (m_settings->fractionDisplay()) {
|
||||
|
|
|
@ -25,9 +25,10 @@
|
|||
#include "qalculate_applet.h"
|
||||
|
||||
#include <QCheckBox>
|
||||
class KComboBox;
|
||||
#include <QSpinBox>
|
||||
|
||||
class KComboBox;
|
||||
|
||||
class QalculateSettings : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
|
|
@ -124,7 +124,7 @@ ConverterRunner::ConverterRunner(QObject* parent, const QVariantList &args)
|
|||
setObjectName(QLatin1String( "Converter" ));
|
||||
|
||||
m_separators << QString( CONVERSION_CHAR );
|
||||
m_separators << i18nc("list of words that can used as amount of 'unit1' [in|to|as] 'unit2'",
|
||||
m_separators << i18nc("list of words that can be used as amount of 'unit1' [in|to|as] 'unit2'",
|
||||
"in;to;as").split(QLatin1Char( ';' ));
|
||||
|
||||
//can not ignore commands: we have things like m4
|
||||
|
|
Loading…
Add table
Reference in a new issue