summaryrefslogtreecommitdiffstats
path: root/src/modules/options/dialog.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 18:31:12 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 18:31:12 +0000
commit0a80cfd57d271dd44221467efb426675fa470356 (patch)
tree6f503a31aa078eaf8fa015cf1749808529d49fc9 /src/modules/options/dialog.cpp
parent3329e5a804e28ef3f5eb51d1e7affdd5a508e8f2 (diff)
downloadkvirc-0a80cfd57d271dd44221467efb426675fa470356.tar.gz
kvirc-0a80cfd57d271dd44221467efb426675fa470356.zip
TQt4 port kvirc
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kvirc@1238719 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/modules/options/dialog.cpp')
-rw-r--r--src/modules/options/dialog.cpp220
1 files changed, 110 insertions, 110 deletions
diff --git a/src/modules/options/dialog.cpp b/src/modules/options/dialog.cpp
index bebcae3e..6b5f6e80 100644
--- a/src/modules/options/dialog.cpp
+++ b/src/modules/options/dialog.cpp
@@ -32,45 +32,45 @@
#include "kvi_module.h"
#include "kvi_styled_controls.h"
#include "kvi_pointerhashtable.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include "kvi_accel.h"
-#include <qlabel.h>
+#include <tqlabel.h>
#include "kvi_tal_vbox.h"
-#include <qsplitter.h>
+#include <tqsplitter.h>
#include "kvi_tal_widgetstack.h"
-#include <qpushbutton.h>
+#include <tqpushbutton.h>
#include "kvi_tal_tooltip.h"
#ifdef COMPILE_USE_QT4
- #include <q3header.h>
+ #include <tq3header.h>
#else
- #include <qheader.h>
- #include <qobjectlist.h>
+ #include <tqheader.h>
+ #include <tqobjectlist.h>
#endif
#include "kvi_tal_popupmenu.h"
-#include <qtoolbutton.h>
-#include <qcheckbox.h>
+#include <tqtoolbutton.h>
+#include <tqcheckbox.h>
#include <kvi_tal_groupbox.h>
-#include <qpainter.h>
-#include <qfont.h>
-#include <qevent.h>
+#include <tqpainter.h>
+#include <tqfont.h>
+#include <tqevent.h>
//extern KviModule * g_pOptionsModule;
-extern KviPointerHashTable<QString,KviOptionsDialog> * g_pOptionsDialogDict;
+extern KviPointerHashTable<TQString,KviOptionsDialog> * g_pOptionsDialogDict;
extern KVIRC_API KviApp * g_pApp;
extern KviOptionsInstanceManager * g_pOptionsInstanceManager;
-KviGeneralOptionsFrontWidget::KviGeneralOptionsFrontWidget(QWidget *parent,const QString &szText)
-:KviOptionsWidget(parent,"general_options_front_widget")
+KviGeneralOptionsFrontWidget::KviGeneralOptionsFrontWidget(TQWidget *tqparent,const TQString &szText)
+:KviOptionsWidget(tqparent,"general_options_front_widget")
{
createLayout(1,1);
- QLabel * l = new QLabel(szText,this);
+ TQLabel * l = new TQLabel(szText,this);
#ifdef COMPILE_USE_QT4
l->setWordWrap(true);
#endif
- l->setAlignment(Qt::AlignTop);
- layout()->addWidget(l,0,0);
+ l->tqsetAlignment(TQt::AlignTop);
+ tqlayout()->addWidget(l,0,0);
}
KviGeneralOptionsFrontWidget::~KviGeneralOptionsFrontWidget()
@@ -80,8 +80,8 @@ KviGeneralOptionsFrontWidget::~KviGeneralOptionsFrontWidget()
-KviOptionsListViewItem::KviOptionsListViewItem(KviTalListView *parent,KviOptionsWidgetInstanceEntry * e)
-:KviTalListViewItem(parent,e->szName)
+KviOptionsListViewItem::KviOptionsListViewItem(KviTalListView *tqparent,KviOptionsWidgetInstanceEntry * e)
+:KviTalListViewItem(tqparent,e->szName)
{
m_pInstanceEntry = e;
m_pOptionsWidget = 0;
@@ -89,8 +89,8 @@ KviOptionsListViewItem::KviOptionsListViewItem(KviTalListView *parent,KviOptions
setPixmap(0,*(g_pIconManager->getSmallIcon(e->iIcon)));
}
-KviOptionsListViewItem::KviOptionsListViewItem(KviTalListViewItem *parent,KviOptionsWidgetInstanceEntry * e)
-:KviTalListViewItem(parent,e->szName)
+KviOptionsListViewItem::KviOptionsListViewItem(KviTalListViewItem *tqparent,KviOptionsWidgetInstanceEntry * e)
+:KviTalListViewItem(tqparent,e->szName)
{
m_pInstanceEntry = e;
m_pOptionsWidget = 0;
@@ -102,14 +102,14 @@ KviOptionsListViewItem::~KviOptionsListViewItem()
{
}
-void KviOptionsListViewItem::paintCell(QPainter * p,const QColorGroup & cg,int column,int width,int align)
+void KviOptionsListViewItem::paintCell(TQPainter * p,const TQColorGroup & cg,int column,int width,int align)
{
if(m_bHighlighted)
{
- QColorGroup tmp(cg);
- tmp.setColor(QColorGroup::Base,Qt::red);
- tmp.setColor(QColorGroup::Background,Qt::red);
- tmp.setColor(QColorGroup::Text,Qt::yellow);
+ TQColorGroup tmp(cg);
+ tmp.setColor(TQColorGroup::Base,TQt::red);
+ tmp.setColor(TQColorGroup::Background,TQt::red);
+ tmp.setColor(TQColorGroup::Text,TQt::yellow);
KviTalListViewItem::paintCell(p,tmp,column,width,align);
} else {
KviTalListViewItem::paintCell(p,cg,column,width,align);
@@ -117,44 +117,44 @@ void KviOptionsListViewItem::paintCell(QPainter * p,const QColorGroup & cg,int c
}
-KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
-: QDialog(par,"general_options_dialog")
+KviOptionsDialog::KviOptionsDialog(TQWidget * par,const TQString &szGroup)
+: TQDialog(par,"general_options_dialog")
{
setIcon(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_KVIRC)));
m_szGroup = szGroup;
- QString szDialogTitle;
+ TQString szDialogTitle;
- if(szGroup.isEmpty() || KviQString::equalCI(szGroup,"general"))
+ if(szGroup.isEmpty() || KviTQString::equalCI(szGroup,"general"))
{
szDialogTitle = __tr2qs_ctx("General Preferences","options");
- } else if(KviQString::equalCI(szGroup,"theme"))
+ } else if(KviTQString::equalCI(szGroup,"theme"))
{
szDialogTitle = __tr2qs_ctx("Theme Preferences","options");
} else {
szDialogTitle = __tr2qs_ctx("KVIrc Preferences","options");
}
- QString szDialog = __tr2qs_ctx("This dialog contains a set of KVIrc settings.<br> Use the icons " \
+ TQString szDialog = __tr2qs_ctx("This dialog contains a set of KVIrc settings.<br> Use the icons " \
"on the left to navigate through the option pages. The text box in the " \
"bottom left corner is a small search engine. It will highlight the " \
"pages that contain options related to the search term you have entered.","options");
- QString szInfoTips;
+ TQString szInfoTips;
#ifdef COMPILE_INFO_TIPS
szInfoTips = __tr2qs_ctx("Many settings have tooltips that can be shown by holding " \
"the cursor over their label for a few seconds.","options");
#else
szInfoTips = "";
#endif
- QString szOkCancelButtons = __tr2qs_ctx("When you have finished, click \"<b>OK</b>\" to accept your changes " \
+ TQString szOkCancelButtons = __tr2qs_ctx("When you have finished, click \"<b>OK</b>\" to accept your changes " \
"or \"<b>Cancel</b>\" to discard them. Clicking \"<b>Apply</b>\" will commit your " \
"changes without closing the window.","options");
- QString szFrontText = QString(
+ TQString szFrontText = TQString(
"<table width=\"100%\" height=\"100%\" valign=\"top\" align=\"center\" cellpadding=\"4\">" \
"<tr>" \
"<td bgcolor=\"#303030\" valign=\"top\">" \
@@ -179,13 +179,13 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
"</td>" \
"</tr>" \
"</table>"
- ).arg(szDialogTitle).arg(szDialog).arg(szInfoTips).arg(szOkCancelButtons);
+ ).tqarg(szDialogTitle).tqarg(szDialog).tqarg(szInfoTips).tqarg(szOkCancelButtons);
- QString szCaption = szDialogTitle + " - KVIrc";
+ TQString szCaption = szDialogTitle + " - KVIrc";
setCaption(szCaption);
- QGridLayout * g1 = new QGridLayout(this,2,5,8,8);
- QSplitter * spl = new QSplitter(Qt::Horizontal,this);
+ TQGridLayout * g1 = new TQGridLayout(this,2,5,8,8);
+ TQSplitter * spl = new TQSplitter(Qt::Horizontal,this);
g1->addMultiCellWidget(spl,0,0,0,4);
@@ -199,22 +199,22 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
m_pListView->header()->hide();
m_pListView->setRootIsDecorated(true);
m_pListView->setSorting(-1);
- connect(m_pListView,SIGNAL(selectionChanged(KviTalListViewItem *)),this,SLOT(listViewItemSelectionChanged(KviTalListViewItem *)));
+ connect(m_pListView,TQT_SIGNAL(selectionChanged(KviTalListViewItem *)),this,TQT_SLOT(listViewItemSelectionChanged(KviTalListViewItem *)));
KviTalHBox * hbox = new KviTalHBox(vbox);
vbox->setSpacing(2);
vbox->setMargin(0);
- m_pSearchLineEdit = new QLineEdit(hbox);
- connect(m_pSearchLineEdit,SIGNAL(returnPressed()),this,SLOT(searchClicked()));
+ m_pSearchLineEdit = new TQLineEdit(hbox);
+ connect(m_pSearchLineEdit,TQT_SIGNAL(returnPressed()),this,TQT_SLOT(searchClicked()));
m_pSearchButton = new KviStyledToolButton(hbox);
m_pSearchButton->setUsesBigPixmap(false);
m_pSearchButton->setIconSet(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_SEARCH)));
- connect(m_pSearchButton,SIGNAL(clicked()),this,SLOT(searchClicked()));
- connect(m_pSearchLineEdit,SIGNAL(textChanged(const QString &)),this,SLOT(searchLineEditTextChanged(const QString &)));
+ connect(m_pSearchButton,TQT_SIGNAL(clicked()),this,TQT_SLOT(searchClicked()));
+ connect(m_pSearchLineEdit,TQT_SIGNAL(textChanged(const TQString &)),this,TQT_SLOT(searchLineEditTextChanged(const TQString &)));
#ifdef COMPILE_INFO_TIPS
- QString szTip = __tr2qs_ctx("<p>This is the search tool for this options dialog.</p>" \
+ TQString szTip = __tr2qs_ctx("<p>This is the search tool for this options dialog.</p>" \
"<p>You can enter a search term either in your native " \
"language or in english and press the button on the right. " \
"The pages that contain some options related to the " \
@@ -228,11 +228,11 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
vbox->setSpacing(2);
vbox->setMargin(0);
- m_pCategoryLabel = new QLabel("<b>&nbsp;</b>",vbox,"labgeneraloptions");
+ m_pCategoryLabel = new TQLabel("<b>&nbsp;</b>",vbox,"labgeneraloptions");
//m_pCategoryLabel->setMargin(3);
- QFrame * f = new QFrame(vbox);
- f->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ TQFrame * f = new TQFrame(vbox);
+ f->setFrameStyle(TQFrame::HLine | TQFrame::Sunken);
// Widget stack
m_pWidgetStack = new KviTalWidgetStack(vbox);
@@ -245,24 +245,24 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
// Ok,Cancel,Help
- QPushButton * b = new QPushButton(__tr2qs_ctx("&OK","options"),this,"btnok");
+ TQPushButton * b = new TQPushButton(__tr2qs_ctx("&OK","options"),this,"btnok");
KviTalToolTip::add(b,__tr2qs_ctx("Close this dialog, accepting all changes.","options"));
- connect(b,SIGNAL(clicked()),this,SLOT(okClicked()));
+ connect(b,TQT_SIGNAL(clicked()),this,TQT_SLOT(okClicked()));
//b->setMinimumWidth(whatIsThisWidth);
b->setIconSet(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_ACCEPT)));
g1->addWidget(b,1,2);
- b = new QPushButton(__tr2qs_ctx("&Apply","options"),this,"btnapply");
+ b = new TQPushButton(__tr2qs_ctx("&Apply","options"),this,"btnapply");
KviTalToolTip::add(b,__tr2qs_ctx("Commit all changes immediately.","options"));
- connect(b,SIGNAL(clicked()),this,SLOT(applyClicked()));
+ connect(b,TQT_SIGNAL(clicked()),this,TQT_SLOT(applyClicked()));
b->setIconSet(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_ACCEPT)));
g1->addWidget(b,1,3);
- b = new QPushButton(__tr2qs_ctx("Cancel","options"),this,"btncancel");
+ b = new TQPushButton(__tr2qs_ctx("Cancel","options"),this,"btncancel");
KviTalToolTip::add(b,__tr2qs_ctx("Close this dialog, discarding all changes.","options"));
b->setDefault(true);
//b->setMinimumWidth(whatIsThisWidth);
- connect(b,SIGNAL(clicked()),this,SLOT(cancelClicked()));
+ connect(b,TQT_SIGNAL(clicked()),this,TQT_SLOT(cancelClicked()));
b->setIconSet(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_DISCARD)));
g1->addWidget(b,1,4);
@@ -272,7 +272,7 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
fillListView(0,g_pOptionsInstanceManager->instanceEntryTree(),szGroup);
- if(!parent())
+ if(!tqparent())
{
if(KVI_OPTION_RECT(KviOption_rectGeneralOptionsDialogGeometry).y() < 5)
@@ -287,26 +287,26 @@ KviOptionsDialog::KviOptionsDialog(QWidget * par,const QString &szGroup)
}
KviAccel *a = new KviAccel( this );
- a->connectItem( a->insertItem(Qt::Key_Escape), this,SLOT(close()) );
+ a->connectItem( a->insertItem(TQt::Key_Escape), this,TQT_SLOT(close()) );
}
KviOptionsDialog::~KviOptionsDialog()
{
- if(!parent())KVI_OPTION_RECT(KviOption_rectGeneralOptionsDialogGeometry) = QRect(pos().x(),pos().y(),
+ if(!tqparent())KVI_OPTION_RECT(KviOption_rectGeneralOptionsDialogGeometry) = TQRect(pos().x(),pos().y(),
size().width(),size().height());
if(g_pOptionsDialogDict)
g_pOptionsDialogDict->remove(m_szGroup);
}
-void KviOptionsDialog::searchLineEditTextChanged(const QString &)
+void KviOptionsDialog::searchLineEditTextChanged(const TQString &)
{
- QString txt = m_pSearchLineEdit->text().stripWhiteSpace();
+ TQString txt = m_pSearchLineEdit->text().stripWhiteSpace();
m_pSearchButton->setEnabled(txt.length() > 0);
}
-bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStringList &lKeywords)
+bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const TQStringList &lKeywords)
{
//debug("recursive search:");
if(!pItem)return false;
@@ -320,34 +320,34 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
bool bFoundSomethingHere = false;
KviPointerHashTable<void *,bool> lOptionWidgetsToMark;
lOptionWidgetsToMark.setAutoDelete(true);
- QTabWidget * pTabWidgetToMark = 0;
+ TQTabWidget * pTabWidgetToMark = 0;
- QObject * o;
+ TQObject * o;
#ifdef COMPILE_USE_QT4
- QObjectList ol = pItem->m_pOptionsWidget->queryList();
+ TQObjectList ol = pItem->m_pOptionsWidget->queryList();
if(ol.count() > 0)
{
- for(QObjectList::Iterator it = ol.begin();it != ol.end();++it)
+ for(TQObjectList::Iterator it = ol.begin();it != ol.end();++it)
{
o = *it;
#else
- QObjectList * ol = pItem->m_pOptionsWidget->queryList();
+ TQObjectList * ol = pItem->m_pOptionsWidget->queryList();
if(ol)
{
- QObjectListIt it(*ol);
+ TQObjectListIt it(*ol);
while((o = it.current())/* && (!bFoundSomethingHere)*/)
{
#endif
- QString szText;
- if(o->inherits("QLabel"))szText = ((QLabel *)o)->text();
- else if(o->inherits("QCheckBox"))szText = ((QCheckBox *)o)->text();
+ TQString szText;
+ if(o->inherits(TQLABEL_OBJECT_NAME_STRING))szText = ((TQLabel *)o)->text();
+ else if(o->inherits(TQCHECKBOX_OBJECT_NAME_STRING))szText = ((TQCheckBox *)o)->text();
else if(o->inherits("KviTalGroupBox"))szText = ((KviTalGroupBox *)o)->title();
#ifdef COMPILE_INFO_TIPS
- if(o->inherits("QWidget"))
+ if(o->inherits(TQWIDGET_OBJECT_NAME_STRING))
#ifdef COMPILE_USE_QT4
- szText.append(((QWidget *)o)->toolTip());
+ szText.append(((TQWidget *)o)->toolTip());
#else
- szText.append(QToolTip::textFor((QWidget*)o));
+ szText.append(TQToolTip::textFor((TQWidget*)o));
#endif
#endif
if(!szText.isEmpty())
@@ -356,9 +356,9 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
for(int j=0;j<lKeywords.count();j++)
{
#ifdef COMPILE_USE_QT4
- if(szText.find(lKeywords.at(j),0,false) == -1)
+ if(szText.tqfind(lKeywords.at(j),0,false) == -1)
#else
- if(szText.find(*(lKeywords.at(j)),0,false) == -1)
+ if(szText.tqfind(*(lKeywords.at(j)),0,false) == -1)
#endif
{
bOk = false;
@@ -370,35 +370,35 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
bFoundSomethingHere = true;
}
- if(o->inherits("QWidget"))
+ if(o->inherits(TQWIDGET_OBJECT_NAME_STRING))
{
- QWidget* pWidget=(QWidget*)o;
- QFont font = pWidget->font();
+ TQWidget* pWidget=(TQWidget*)o;
+ TQFont font = pWidget->font();
font.setBold(bOk);
font.setUnderline(bOk);
pWidget->setFont(font);
- // if there is a QTabWidget in the parent chain, signal it in the tab text
- QObject * pParent = pWidget->parent();
+ // if there is a TQTabWidget in the tqparent chain, signal it in the tab text
+ TQObject * pParent = pWidget->tqparent();
while(pParent)
{
- if(pParent->inherits("QTabWidget"))
+ if(pParent->inherits(TQTABWIDGET_OBJECT_NAME_STRING))
{
- pTabWidgetToMark = (QTabWidget *)pParent;
+ pTabWidgetToMark = (TQTabWidget *)pParent;
break;
}
- pParent = pParent->parent();
+ pParent = pParent->tqparent();
}
if(pTabWidgetToMark)
{
- // lookup the KviOptionsWidget parent
- pParent = pWidget->parent();
+ // lookup the KviOptionsWidget tqparent
+ pParent = pWidget->tqparent();
while(pParent)
{
if(pParent->inherits("KviOptionsWidget"))
{
- bool * pExistingBool = lOptionWidgetsToMark.find(pParent);
+ bool * pExistingBool = lOptionWidgetsToMark.tqfind(pParent);
if(pExistingBool)
{
if(bOk)
@@ -408,7 +408,7 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
}
break;
}
- pParent = pParent->parent();
+ pParent = pParent->tqparent();
}
}
}
@@ -429,16 +429,16 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
while(bool * pBool = it.current())
{
KviOptionsWidget * pOptionsWidget = (KviOptionsWidget *)it.currentKey();
- QString szTxt = pTabWidgetToMark->tabLabel(pOptionsWidget);
- if(KviQString::equalCIN(szTxt,">>> ",4))
+ TQString szTxt = pTabWidgetToMark->tabLabel(pOptionsWidget);
+ if(KviTQString::equalCIN(szTxt,">>> ",4))
{
- szTxt.replace(">>> ","");
- szTxt.replace(" <<<","");
+ szTxt.tqreplace(">>> ","");
+ szTxt.tqreplace(" <<<","");
}
if(*pBool)
{
szTxt.insert(0,">>> ");
- szTxt += QString(" <<<");
+ szTxt += TQString(" <<<");
}
pTabWidgetToMark->setTabLabel(pOptionsWidget,szTxt);
++it;
@@ -460,7 +460,7 @@ bool KviOptionsDialog::recursiveSearch(KviOptionsListViewItem * pItem,const QStr
return (bFoundSomethingInside || bFoundSomethingHere);
}
-void KviOptionsDialog::search(const QStringList &lKeywords)
+void KviOptionsDialog::search(const TQStringList &lKeywords)
{
m_pListView->setUpdatesEnabled(false);
@@ -475,20 +475,20 @@ void KviOptionsDialog::search(const QStringList &lKeywords)
m_pListView->triggerUpdate();
}
-void KviOptionsDialog::search(const QString &szKeywords)
+void KviOptionsDialog::search(const TQString &szKeywords)
{
- QStringList lKeywords = QStringList::split(" ",szKeywords,false);
+ TQStringList lKeywords = TQStringList::split(" ",szKeywords,false);
search(lKeywords);
}
void KviOptionsDialog::searchClicked()
{
- QString szTxt = m_pSearchLineEdit->text().stripWhiteSpace();
+ TQString szTxt = m_pSearchLineEdit->text().stripWhiteSpace();
if(!szTxt.isEmpty())
search(szTxt);
}
-void KviOptionsDialog::fillListView(KviTalListViewItem * p,KviPointerList<KviOptionsWidgetInstanceEntry> * l,const QString &szGroup,bool bNotContainedOnly)
+void KviOptionsDialog::fillListView(KviTalListViewItem * p,KviPointerList<KviOptionsWidgetInstanceEntry> * l,const TQString &szGroup,bool bNotContainedOnly)
{
if(!l)return;
@@ -503,7 +503,7 @@ void KviOptionsDialog::fillListView(KviTalListViewItem * p,KviPointerList<KviOpt
{
// must be in the correct group
// if we want only containers then well.. must be one
- e->bDoInsert = KviQString::equalCI(szGroup,e->szGroup) && ((!bNotContainedOnly) || e->bIsContainer || e->bIsNotContained);
+ e->bDoInsert = KviTQString::equalCI(szGroup,e->szGroup) && ((!bNotContainedOnly) || e->bIsContainer || e->bIsNotContained);
KviOptionsWidgetInstanceEntry * ee = tmp.first();
int idx = 0;
while(ee)
@@ -534,10 +534,10 @@ void KviOptionsDialog::fillListView(KviTalListViewItem * p,KviPointerList<KviOpt
{
if(e->bIsContainer)
{
- // it's a container: add only eventual not contained children (containers or explicitly marked as not contained)
+ // it's a container: add only eventual not contained tqchildren (containers or explicitly marked as not contained)
fillListView(it,e->pChildList,szGroup,true);
} else {
- // it's not a container, add any children
+ // it's not a container, add any tqchildren
fillListView(it,e->pChildList,szGroup,false);
}
}
@@ -548,14 +548,14 @@ void KviOptionsDialog::listViewItemSelectionChanged(KviTalListViewItem *it)
{
if(it)
{
- QString str = it->text(0);
- KviTalListViewItem * par = it->parent();
+ TQString str = it->text(0);
+ KviTalListViewItem * par = it->tqparent();
while(par)
{
str.prepend(" :: ");
str.prepend(par->text(0));
- par = par->parent();
+ par = par->tqparent();
}
str.prepend("<b>");
str += "</b>";
@@ -578,7 +578,7 @@ KviOptionsListViewItem * KviOptionsDialog::findItemByPage(KviOptionsListViewItem
if(it->m_pOptionsWidget == pPage)return it;
KviOptionsListViewItem *i;
- // run through the children
+ // run through the tqchildren
i = (KviOptionsListViewItem *)(it->firstChild());
if(i)
{
@@ -586,7 +586,7 @@ KviOptionsListViewItem * KviOptionsDialog::findItemByPage(KviOptionsListViewItem
if(i)return i;
}
- // not found in the children tree.. look in the next sibling
+ // not found in the tqchildren tree.. look in the next sibling
i = (KviOptionsListViewItem *)(it->nextSibling());
if(i)
{
@@ -639,7 +639,7 @@ void KviOptionsDialog::cancelClicked()
delete this;
}
-void KviOptionsDialog::closeEvent(QCloseEvent *e)
+void KviOptionsDialog::closeEvent(TQCloseEvent *e)
{
e->ignore();
delete this;
@@ -647,7 +647,7 @@ void KviOptionsDialog::closeEvent(QCloseEvent *e)
void KviOptionsDialog::recursiveCommit(KviOptionsListViewItem *it)
{
- // First commit the children
+ // First commit the tqchildren
if(!it) return;
KviOptionsListViewItem *it2 = (KviOptionsListViewItem *)it->firstChild();
while(it2)
@@ -655,7 +655,7 @@ void KviOptionsDialog::recursiveCommit(KviOptionsListViewItem *it)
recursiveCommit(it2);
it2 = (KviOptionsListViewItem *)it2->nextSibling();
}
- // then the parents
+ // then the tqparents
if(it->m_pOptionsWidget)
{
it->m_pOptionsWidget->commit();
@@ -664,9 +664,9 @@ void KviOptionsDialog::recursiveCommit(KviOptionsListViewItem *it)
}
//refreshListView(); // <-- this tends to jump into infinite recursion
}
-void KviOptionsDialog::keyPressEvent( QKeyEvent * e )
+void KviOptionsDialog::keyPressEvent( TQKeyEvent * e )
{
- if(e->key()==Qt::Key_Return)
+ if(e->key()==TQt::Key_Return)
e->accept();
else
e->ignore();