summaryrefslogtreecommitdiffstats
path: root/src/kvirc/kvs
diff options
context:
space:
mode:
Diffstat (limited to 'src/kvirc/kvs')
-rw-r--r--src/kvirc/kvs/kvi_kvs_corefunctions_af.cpp4
-rw-r--r--src/kvirc/kvs/kvi_kvs_coresimplecommands_af.cpp5
-rw-r--r--src/kvirc/kvs/kvi_kvs_coresimplecommands_gl.cpp7
-rw-r--r--src/kvirc/kvs/kvi_kvs_coresimplecommands_mr.cpp6
-rw-r--r--src/kvirc/kvs/kvi_kvs_object.cpp65
-rw-r--r--src/kvirc/kvs/kvi_kvs_popupmenu.cpp3
-rw-r--r--src/kvirc/kvs/kvi_kvs_processmanager.cpp4
-rw-r--r--src/kvirc/kvs/kvi_kvs_variant.cpp4
8 files changed, 0 insertions, 98 deletions
diff --git a/src/kvirc/kvs/kvi_kvs_corefunctions_af.cpp b/src/kvirc/kvs/kvi_kvs_corefunctions_af.cpp
index cc48db1..93d729f 100644
--- a/src/kvirc/kvs/kvi_kvs_corefunctions_af.cpp
+++ b/src/kvirc/kvs/kvi_kvs_corefunctions_af.cpp
@@ -947,11 +947,7 @@ namespace KviKvsCoreFunctions
#ifdef COMPILE_SCRIPTTOOLBAR
"ScriptToolBar",
#endif // COMPILE_SCRIPTTOOLBAR
- #ifdef COMPILE_USE_QT4
- "TQt4",
- #else
"TQt3",
- #endif
#ifdef COMPILE_NEW_KVS
"KVS",
#endif
diff --git a/src/kvirc/kvs/kvi_kvs_coresimplecommands_af.cpp b/src/kvirc/kvs/kvi_kvs_coresimplecommands_af.cpp
index 6eb820e..66d3d96 100644
--- a/src/kvirc/kvs/kvi_kvs_coresimplecommands_af.cpp
+++ b/src/kvirc/kvs/kvi_kvs_coresimplecommands_af.cpp
@@ -47,12 +47,7 @@
#include "kvi_xlib.h" // XBell : THIS SHOULD BE INCLUDED AS LAST!
#include <unistd.h> // for usleep();
- #ifdef COMPILE_USE_QT4
- #include <tqx11info_x11.h>
- #define get_xdisplay QX11Info::display
- #else
#define get_xdisplay tqt_xdisplay
- #endif
#endif
diff --git a/src/kvirc/kvs/kvi_kvs_coresimplecommands_gl.cpp b/src/kvirc/kvs/kvi_kvs_coresimplecommands_gl.cpp
index c46ecb2..d7664ac 100644
--- a/src/kvirc/kvs/kvi_kvs_coresimplecommands_gl.cpp
+++ b/src/kvirc/kvs/kvi_kvs_coresimplecommands_gl.cpp
@@ -37,9 +37,6 @@
#include "kvi_out.h"
-#ifdef COMPILE_USE_QT4
- #include <tq3mimefactory.h>
-#endif
namespace KviKvsCoreSimpleCommands
{
@@ -139,11 +136,7 @@ namespace KviKvsCoreSimpleCommands
TQString szOriginal = szTopic;
TQString topik = szTopic;
-#ifdef COMPILE_USE_QT4
- TQStringList pl = Q3MimeSourceFactory::defaultFactory()->filePath();
-#else
TQStringList pl = TQMimeSourceFactory::defaultFactory()->filePath();
-#endif
bool bLowCaseTried = false;
bool bFound = KviFileUtils::fileExists(szTopic);
diff --git a/src/kvirc/kvs/kvi_kvs_coresimplecommands_mr.cpp b/src/kvirc/kvs/kvi_kvs_coresimplecommands_mr.cpp
index d398b18..701a265 100644
--- a/src/kvirc/kvs/kvi_kvs_coresimplecommands_mr.cpp
+++ b/src/kvirc/kvs/kvi_kvs_coresimplecommands_mr.cpp
@@ -1320,15 +1320,9 @@ namespace KviKvsCoreSimpleCommands
KVSCSC_PARAMETER("parameters",KVS_PT_STRINGLIST,KVS_PF_OPTIONAL,l)
KVSCSC_PARAMETERS_END
-#ifdef COMPILE_USE_QT4
- TQProcess proc;
- proc.start(szCommand,l);
- // FIXME: KVSCSC_pContext->warning(__tr2qs("Failed to execute command '%Q'"),&szCommand);
-#else
TQProcess proc(szCommand);
for ( TQStringList::Iterator it = l.begin(); it != l.end(); ++it ) proc.addArgument(*it);
if(!proc.start())KVSCSC_pContext->warning(__tr2qs("Failed to execute command '%Q'"),&szCommand);
-#endif
return true;
}
};
diff --git a/src/kvirc/kvs/kvi_kvs_object.cpp b/src/kvirc/kvs/kvi_kvs_object.cpp
index 46f6efb..3bfca49 100644
--- a/src/kvirc/kvs/kvi_kvs_object.cpp
+++ b/src/kvirc/kvs/kvi_kvs_object.cpp
@@ -1017,10 +1017,7 @@ bool KviKvsObject::function_killTimer(KviKvsObjectFunctionCall * c)
bool KviKvsObject::function_killTimers(KviKvsObjectFunctionCall * c)
{
- // FIXME: QT4 does not seem to have TQObject::killTimers()
-#ifndef COMPILE_USE_QT4
killTimers();
-#endif
return true;
}
@@ -1045,27 +1042,16 @@ bool KviKvsObject::function_listProperties(KviKvsObjectFunctionCall * c)
const TQMetaObject *o = m_pObject->metaObject();
if(!bArray)
w->output(KVI_OUT_SYSTEMMESSAGE,__tr2qs("Properties for TQt class %s"),o->className());
-#ifndef COMPILE_USE_QT4
while(o)
{
-#endif
kvs_int_t idx = 0;
- #ifdef COMPILE_USE_QT4
- TQMetaProperty prop = o->property(idx);
- const TQMetaProperty *p = &prop;
- #else
const TQMetaProperty *p = o->property(idx);
- #endif
while(p)
{
TQString szOut;
TQString szName = p->name();
- #ifdef COMPILE_USE_QT4
- TQString szType = p->typeName();
- #else
TQString szType = p->type();
- #endif
if(bArray)
KviTQString::sprintf(szOut,"%Q, %Q",&szName,&szType);
else {
@@ -1076,7 +1062,6 @@ bool KviKvsObject::function_listProperties(KviKvsObjectFunctionCall * c)
if(p->isEnumType())
{
szOut += ", enum(";
-#ifndef COMPILE_USE_QT4
// FIXME: TQt 4.x needs TQMetaEnum for this loop
TQStrList le = p->enumKeys();
int i = 0;
@@ -1088,41 +1073,23 @@ bool KviKvsObject::function_listProperties(KviKvsObjectFunctionCall * c)
szOut.append(", ");
szOut.append(c2);
}
-#endif
szOut += ")";
}
-#ifdef COMPILE_USE_QT4
- // FIXME: QT4 Need to read better the docs and check the changes: there seem to be too many
- // for me to fix now. Actually I need to get the whole executable working...
- if(p->isWritable())szOut += ", writable";
-#else
if(p->isSetType())szOut += ", set";
if(p->writable())szOut += ", writable";
-#endif
if(bArray)
a->set(cnt,new KviKvsVariant(szOut));
else
w->outputNoFmt(KVI_OUT_SYSTEMMESSAGE,szOut);
-#ifdef COMPILE_USE_QT4
- idx++;
- if (idx<o->propertyCount()){
- prop = o->property(idx);
- p = &prop;
- }
- else p=0;
-#else
p = o->property(idx);
idx++;
-#endif
cnt++;
}
-#ifndef COMPILE_USE_QT4
o = o->superClass();
}
-#endif
}
@@ -1153,22 +1120,13 @@ bool KviKvsObject::function_setProperty(KviKvsObjectFunctionCall * c)
return true;
}
-#ifdef COMPILE_USE_QT4
- int idx = m_pObject->metaObject()->indexOfProperty(szName);
-#else
int idx = m_pObject->metaObject()->findProperty(szName,true);
-#endif
if(idx < 0)
{
c->warning(__tr2qs("No TQt property named \"%Q\" for object named \"%Q\" of class %Q"),&szName,&m_szName,&(m_pClass->name()));
return true;
}
-#ifdef COMPILE_USE_QT4
- TQMetaProperty prop = m_pObject->metaObject()->property(idx);
- const TQMetaProperty * p = &prop;
-#else
const TQMetaProperty * p = m_pObject->metaObject()->property(idx,true);
-#endif
if(!p)
{
c->warning(__tr2qs("Can't find property named \"%Q\" for object named \"%Q\" of class %Q: the property is indexed but it doesn't really exist"),&szName,&m_szName,&(m_pClass->name()));
@@ -1186,11 +1144,7 @@ bool KviKvsObject::function_setProperty(KviKvsObjectFunctionCall * c)
{
TQString szKey;
v->asString(szKey);
-#ifdef COMPILE_USE_QT4
- int val = p->enumerator().keyToValue(szKey);
-#else
int val = p->keyToValue(szKey);
-#endif
TQVariant var(val);
m_pObject->setProperty(szName,var);
return true;
@@ -1274,8 +1228,6 @@ bool KviKvsObject::function_setProperty(KviKvsObjectFunctionCall * c)
m_pObject->setProperty(szName,TQVariant(TQRect(iX,iY,iW,iH)));
}
break;
-#ifndef COMPILE_USE_QT4
- // FIXME: QT4 ????
case TQVariant::Color:
{
if(!v->isArray())WRONG_TYPE("array(integer,integer,integer)")
@@ -1354,7 +1306,6 @@ bool KviKvsObject::function_setProperty(KviKvsObjectFunctionCall * c)
}
}
break;
-#endif
default:
c->warning(__tr2qs("Property \"%Q\" for object named \"%Q\" of class %Q has an unsupported data type"),&szName,&m_szName,&(m_pClass->name()));
c->returnValue()->setNothing();
@@ -1384,11 +1335,7 @@ bool KviKvsObject::function_property(KviKvsObjectFunctionCall * c)
return true;
}
-#ifdef COMPILE_USE_QT4
- int idx = m_pObject->metaObject()->indexOfProperty(szName);
-#else
int idx = m_pObject->metaObject()->findProperty(szName,true);
-#endif
if(idx < 0)
{
if (bNoerror) c->returnValue()->setString("No TQt properties");
@@ -1399,12 +1346,7 @@ bool KviKvsObject::function_property(KviKvsObjectFunctionCall * c)
}
return true;
}
-#ifdef COMPILE_USE_QT4
- TQMetaProperty prop = m_pObject->metaObject()->property(idx);
- const TQMetaProperty * p = &prop;
-#else
const TQMetaProperty * p = m_pObject->metaObject()->property(idx,true);
-#endif
if(!p)
{
c->warning(__tr2qs("Can't find property named \"%Q\" for object named \"%Q\" of class %Q: the property is indexed but it doesn't really exist"),&szName,&m_szName,&(m_pClass->name()));
@@ -1422,11 +1364,7 @@ bool KviKvsObject::function_property(KviKvsObjectFunctionCall * c)
if(p->isEnumType())
{
-#ifdef COMPILE_USE_QT4
- c->returnValue()->setString(p->enumerator().valueToKey(v.toInt()));
-#else
c->returnValue()->setString(p->valueToKey(v.toInt()));
-#endif
return true;
}
@@ -1476,8 +1414,6 @@ bool KviKvsObject::function_property(KviKvsObjectFunctionCall * c)
c->returnValue()->setArray(a);
}
break;
-#ifndef COMPILE_USE_QT4
- // FIXME: QT4 ?
case TQVariant::Color:
{
TQColor clr = v.toColor();
@@ -1505,7 +1441,6 @@ bool KviKvsObject::function_property(KviKvsObjectFunctionCall * c)
c->returnValue()->setString(szFlags);
}
break;
-#endif
default:
if (bNoerror) c->returnValue()->setString("Unsupported_data_type");
else
diff --git a/src/kvirc/kvs/kvi_kvs_popupmenu.cpp b/src/kvirc/kvs/kvi_kvs_popupmenu.cpp
index ef52bee..b531904 100644
--- a/src/kvirc/kvs/kvi_kvs_popupmenu.cpp
+++ b/src/kvirc/kvs/kvi_kvs_popupmenu.cpp
@@ -324,10 +324,7 @@ void KviKvsPopupMenuItemLabel::fill(KviKvsPopupMenu * pMenu,KviKvsPopupMenuTopLe
}
m_pLabel = new TQLabel(szText,pMenu);
TQObject::connect(m_pLabel,TQT_SIGNAL(destroyed()),m_pSignalRelay,TQT_SLOT(labelDestroyed()));
-#ifndef COMPILE_USE_QT4
- // FIXME: QT4 Seems to not allow widgets as TQMenu items
pMenu->insertItem(m_pLabel);
-#endif
m_pLabel->setFrameStyle(TQFrame::StyledPanel | TQFrame::Raised);
if(pPix)m_pLabel->setPixmap(*pPix);
}
diff --git a/src/kvirc/kvs/kvi_kvs_processmanager.cpp b/src/kvirc/kvs/kvi_kvs_processmanager.cpp
index c6925e6..ab4a7c1 100644
--- a/src/kvirc/kvs/kvi_kvs_processmanager.cpp
+++ b/src/kvirc/kvs/kvi_kvs_processmanager.cpp
@@ -80,11 +80,7 @@ bool KviKvsProcessAsyncOperation::start()
//
// [02:50:21] <kode54> if ( TQApplication::winVersion() & TQt::WV_NT_based )
// [02:50:41] <kode54> I see another implementation using that, maybe it is the official way of detecting that :[
-#ifdef COMPILE_USE_QT4
- szShell = !(TQSysInfo::WindowsVersion & TQSysInfo::WV_DOS_based) ? "cmd.exe /c" : "command.com /c";
-#else
szShell = "command.com /c";
-#endif
// Thnx kode54 :)
#else
diff --git a/src/kvirc/kvs/kvi_kvs_variant.cpp b/src/kvirc/kvs/kvi_kvs_variant.cpp
index 1510f10..14608be 100644
--- a/src/kvirc/kvs/kvi_kvs_variant.cpp
+++ b/src/kvirc/kvs/kvi_kvs_variant.cpp
@@ -1365,11 +1365,7 @@ KviKvsVariant* KviKvsVariant::unserialize(const TQString& data)
{
KviKvsVariant* pResult = 0;
-#ifdef COMPILE_USE_QT4
- const TQChar * aux = (const TQChar *)data.constData();
-#else
const TQChar * aux = (const TQChar *)data.ucs2();
-#endif
pResult = unserialize(&aux);