summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/HSpinBox.cpp2
-rw-r--r--src/gui/widgets/QuantizeParameters.cpp16
2 files changed, 9 insertions, 9 deletions
diff --git a/src/gui/widgets/HSpinBox.cpp b/src/gui/widgets/HSpinBox.cpp
index e49cf1b..85f4c69 100644
--- a/src/gui/widgets/HSpinBox.cpp
+++ b/src/gui/widgets/HSpinBox.cpp
@@ -42,7 +42,7 @@ TQString HSpinBox::mapValueToText(int j)
int HSpinBox::mapTextToValue( bool* ok )
{
*ok = true;
- float f = atof(text());
+ float f = atof(text().ascii());
return int(f * m_scaleFactor);
}
diff --git a/src/gui/widgets/QuantizeParameters.cpp b/src/gui/widgets/QuantizeParameters.cpp
index 132aaef..a85e3b6 100644
--- a/src/gui/widgets/QuantizeParameters.cpp
+++ b/src/gui/widgets/QuantizeParameters.cpp
@@ -64,12 +64,12 @@ QuantizeParameters::QuantizeParameters(TQWidget *parent,
(BasicQuantizer::getStandardQuantizations())
{
m_mainLayout = new TQGridLayout(this,
- preamble ? 3 : 4, 2,
- preamble ? 10 : 0,
- preamble ? 5 : 4);
+ (!preamble.isNull()) ? 3 : 4, 2,
+ (!preamble.isNull()) ? 10 : 0,
+ (!preamble.isNull()) ? 5 : 4);
int zero = 0;
- if (preamble) {
+ if (!preamble.isNull()) {
TQLabel *label = new TQLabel(preamble, this);
label->tqsetAlignment(TQt::WordBreak);
m_mainLayout->addMultiCellWidget(label, 0, 0, 0, 1);
@@ -168,7 +168,7 @@ QuantizeParameters::QuantizeParameters(TQWidget *parent,
m_postProcessingBox = new TQGroupBox
(1, Qt::Horizontal, i18n("After quantization"), this);
- if (preamble) {
+ if (!preamble.isNull()) {
m_mainLayout->addMultiCellWidget(m_postProcessingBox,
zero, zero + 1,
1, 1);
@@ -217,7 +217,7 @@ QuantizeParameters::QuantizeParameters(TQWidget *parent,
int defaultSwing = 0;
int defaultIterate = 100;
- if (m_configCategory) {
+ if (!m_configCategory.isNull()) {
KConfig *config = kapp->config();
config->setGroup(m_configCategory);
defaultType =
@@ -267,7 +267,7 @@ QuantizeParameters::QuantizeParameters(TQWidget *parent,
advanced = false;
}
- if (preamble || advanced) {
+ if (!preamble.isNull() || advanced) {
m_postProcessingBox->show();
} else {
m_postProcessingBox->hide();
@@ -412,7 +412,7 @@ QuantizeParameters::getQuantizer() const
quantizer = nq;
}
- if (m_configCategory) {
+ if (!m_configCategory.isNull()) {
KConfig *config = kapp->config();
config->setGroup(m_configCategory);
config->writeEntry("quantizetype", type);