summaryrefslogtreecommitdiffstats
path: root/buildtools/autotools/configureoptionswidget.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-14 16:45:05 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-14 16:45:05 +0000
commit48d4a26399959121f33d2bc3bfe51c7827b654fc (patch)
tree5ae5e6e00d3ba330b7b8be9bc097154b6bc739e8 /buildtools/autotools/configureoptionswidget.cpp
parent7e701ace6592d09e1f2c0cf28c7d6d872d78f4f5 (diff)
downloadtdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.tar.gz
tdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.zip
TQt4 port kdevelop
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1236710 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'buildtools/autotools/configureoptionswidget.cpp')
-rw-r--r--buildtools/autotools/configureoptionswidget.cpp52
1 files changed, 26 insertions, 26 deletions
diff --git a/buildtools/autotools/configureoptionswidget.cpp b/buildtools/autotools/configureoptionswidget.cpp
index 0be8903b..1e877a5c 100644
--- a/buildtools/autotools/configureoptionswidget.cpp
+++ b/buildtools/autotools/configureoptionswidget.cpp
@@ -51,7 +51,7 @@ public:
static TQString currentText(TQComboBox *combo, const TQStringList &names)
{
if (combo->currentItem() == -1)
- return TQString::null;
+ return TQString();
return names[combo->currentItem()];
}
static void setCurrentText(TQComboBox *combo, const TQString &str, const TQStringList &names)
@@ -69,10 +69,10 @@ public:
};
-ConfigureOptionsWidget::ConfigureOptionsWidget(AutoProjectPart *part, TQWidget *parent, const char *name)
- : ConfigureOptionsWidgetBase(parent, name)
+ConfigureOptionsWidget::ConfigureOptionsWidget(AutoProjectPart *part, TQWidget *tqparent, const char *name)
+ : ConfigureOptionsWidgetBase(tqparent, name)
{
- config_combo->setValidator(new TQRegExpValidator(TQRegExp("^\\D.*"), this));
+ config_combo->setValidator(new TQRegExpValidator(TQRegExp("^\\D.*"), TQT_TQOBJECT(this)));
m_part = part;
env_groupBox->setColumnLayout( 1, Qt::Vertical );
@@ -98,7 +98,7 @@ ConfigureOptionsWidget::ConfigureOptionsWidget(AutoProjectPart *part, TQWidget *
config_combo->insertStringList(allConfigs);
dirty = false;
- currentConfig = TQString::null;
+ currentConfig = TQString();
configChanged(part->currentBuildConfig());
fixLayout();
@@ -111,20 +111,20 @@ ConfigureOptionsWidget::~ConfigureOptionsWidget()
void ConfigureOptionsWidget::fixLayout()
{
- int w1 = ccompiler_label->sizeHint().width();
- int w2 = cbinary_label->sizeHint().width();
- int w3 = cflags_label->sizeHint().width();
- int w4 = cxxcompiler_label->sizeHint().width();
- int w5 = cxxbinary_label->sizeHint().width();
- int w6 = cxxflags_label->sizeHint().width();
- int w7 = f77compiler_label->sizeHint().width();
- int w8 = f77binary_label->sizeHint().width();
- int w9 = f77flags_label->sizeHint().width();
-
- int w = QMAX(w1, QMAX(w2, w3));
- w = QMAX(w, QMAX(w4, w5));
- w = QMAX(w, QMAX(w6, w7));
- w = QMAX(w, QMAX(w8, w9));
+ int w1 = ccompiler_label->tqsizeHint().width();
+ int w2 = cbinary_label->tqsizeHint().width();
+ int w3 = cflags_label->tqsizeHint().width();
+ int w4 = cxxcompiler_label->tqsizeHint().width();
+ int w5 = cxxbinary_label->tqsizeHint().width();
+ int w6 = cxxflags_label->tqsizeHint().width();
+ int w7 = f77compiler_label->tqsizeHint().width();
+ int w8 = f77binary_label->tqsizeHint().width();
+ int w9 = f77flags_label->tqsizeHint().width();
+
+ int w = TQMAX(w1, TQMAX(w2, w3));
+ w = TQMAX(w, TQMAX(w4, w5));
+ w = TQMAX(w, TQMAX(w6, w7));
+ w = TQMAX(w, TQMAX(w8, w9));
ccompiler_label->setMinimumWidth(w);
cxxcompiler_label->setMinimumWidth(w);
@@ -236,7 +236,7 @@ void ConfigureOptionsWidget::saveSettings(const TQString &config)
DomUtil::writeEntry(dom, prefix + "cxxflags", cxxflags_edit->text());
DomUtil::writeEntry(dom, prefix + "f77flags", f77flags_edit->text());
- if (KMessageBox::questionYesNo(this, i18n("Re-run configure for %1 now?").arg(config), TQString::null, i18n("Rerun"), i18n("Do Not Run")) == KMessageBox::Yes)
+ if (KMessageBox::questionYesNo(this, i18n("Re-run configure for %1 now?").tqarg(config), TQString(), i18n("Rerun"), i18n("Do Not Run")) == KMessageBox::Yes)
TQTimer::singleShot(0, m_part, TQT_SLOT(slotConfigure()));
}
@@ -267,8 +267,8 @@ void ConfigureOptionsWidget::topsourcedirClicked()
void ConfigureOptionsWidget::configComboTextChanged(const TQString &config)
{
- bool canAdd = !allConfigs.contains(config) && !config.contains("/") && !config.isEmpty();
- bool canRemove = allConfigs.contains(config) && config != "default";
+ bool canAdd = !allConfigs.tqcontains(config) && !config.tqcontains("/") && !config.isEmpty();
+ bool canRemove = allConfigs.tqcontains(config) && config != "default";
addconfig_button->setEnabled(canAdd);
removeconfig_button->setEnabled(canRemove);
}
@@ -276,7 +276,7 @@ void ConfigureOptionsWidget::configComboTextChanged(const TQString &config)
void ConfigureOptionsWidget::configChanged(const TQString &config)
{
- if (config == currentConfig || !allConfigs.contains(config))
+ if (config == currentConfig || !allConfigs.tqcontains(config))
return;
if (!currentConfig.isNull() && dirty)
@@ -317,7 +317,7 @@ void ConfigureOptionsWidget::configRemoved()
config_combo->clear();
config_combo->insertStringList(allConfigs);
- currentConfig = TQString::null;
+ currentConfig = TQString();
configChanged("default");
}
@@ -396,7 +396,7 @@ KDevCompilerOptions *ConfigureOptionsWidget::createCompilerOptions(const TQStrin
if (!factory) {
TQString errorMessage = KLibLoader::self()->lastErrorMessage();
KMessageBox::error(0, i18n("There was an error loading the module %1.\n"
- "The diagnostics is:\n%2").arg(service->name()).arg(errorMessage));
+ "The diagnostics is:\n%2").tqarg(service->name()).tqarg(errorMessage));
exit(1);
}
@@ -405,7 +405,7 @@ KDevCompilerOptions *ConfigureOptionsWidget::createCompilerOptions(const TQStrin
if (prop.isValid())
args = TQStringList::split(" ", prop.toString());
- TQObject *obj = factory->create(this, service->name().latin1(),
+ TQObject *obj = factory->create(TQT_TQOBJECT(this), service->name().latin1(),
"KDevCompilerOptions", args);
if (!obj->inherits("KDevCompilerOptions")) {