summaryrefslogtreecommitdiffstats
path: root/kicker/libkicker/paneldrag.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:33:34 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:33:34 +0000
commitc663b6440964f6ac48027143ac9e63298991f9d0 (patch)
tree6d8b0c5a5f9db1ee16acf98b1397cea9126b281d /kicker/libkicker/paneldrag.cpp
parenta061f7191beebb0e4a3b0c0a7c534ec5f22f2dc7 (diff)
downloadtdebase-c663b6440964f6ac48027143ac9e63298991f9d0.tar.gz
tdebase-c663b6440964f6ac48027143ac9e63298991f9d0.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1157639 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kicker/libkicker/paneldrag.cpp')
-rw-r--r--kicker/libkicker/paneldrag.cpp52
1 files changed, 26 insertions, 26 deletions
diff --git a/kicker/libkicker/paneldrag.cpp b/kicker/libkicker/paneldrag.cpp
index 871ac1d96..1fb6b9ce6 100644
--- a/kicker/libkicker/paneldrag.cpp
+++ b/kicker/libkicker/paneldrag.cpp
@@ -24,14 +24,14 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include <sys/types.h>
#include <unistd.h>
-#include <qbuffer.h>
+#include <tqbuffer.h>
#include "paneldrag.h"
#define PANELDRAG_BUFSIZE sizeof(BaseContainer*) + sizeof(pid_t)
-PanelDrag::PanelDrag(BaseContainer* container, QWidget* dragSource)
- : QDragObject(dragSource, 0)
+PanelDrag::PanelDrag(BaseContainer* container, TQWidget* dragSource)
+ : TQDragObject(dragSource, 0)
{
pid_t source_pid = getpid();
@@ -44,9 +44,9 @@ PanelDrag::~PanelDrag()
{
}
-bool PanelDrag::decode(const QMimeSource* e, BaseContainer** container)
+bool PanelDrag::decode(const TQMimeSource* e, BaseContainer** container)
{
- QByteArray a = e->encodedData("application/basecontainerptr");
+ TQByteArray a = e->encodedData("application/basecontainerptr");
if (a.size() != PANELDRAG_BUFSIZE)
{
@@ -55,25 +55,25 @@ bool PanelDrag::decode(const QMimeSource* e, BaseContainer** container)
pid_t target_pid = getpid();
pid_t source_pid;
- memcpy(&source_pid, a.data() + sizeof(QObject*), sizeof(pid_t));
+ memcpy(&source_pid, a.data() + sizeof(TQObject*), sizeof(pid_t));
if (source_pid == target_pid)
{
- memcpy(container, a.data(), sizeof(QObject*));
+ memcpy(container, a.data(), sizeof(TQObject*));
return true;
}
return false;
}
-bool PanelDrag::canDecode(const QMimeSource *e)
+bool PanelDrag::canDecode(const TQMimeSource *e)
{
if (!e->provides("application/basecontainerptr"))
{
return false;
}
- QByteArray a = e->encodedData("application/basecontainerptr");
+ TQByteArray a = e->encodedData("application/basecontainerptr");
if (a.size() != PANELDRAG_BUFSIZE)
{
return false;
@@ -91,15 +91,15 @@ bool PanelDrag::canDecode(const QMimeSource *e)
return true;
}
-QByteArray PanelDrag::encodedData(const char * mimeType) const
+TQByteArray PanelDrag::encodedData(const char * mimeType) const
{
- if (QString("application/basecontainerptr") == mimeType &&
+ if (TQString("application/basecontainerptr") == mimeType &&
a.size() == PANELDRAG_BUFSIZE)
{
return a;
}
- return QByteArray();
+ return TQByteArray();
}
const char * PanelDrag::format(int i) const
@@ -113,12 +113,12 @@ const char * PanelDrag::format(int i) const
}
-AppletInfoDrag::AppletInfoDrag(const AppletInfo& info, QWidget *dragSource)
- : QDragObject(dragSource, 0)
+AppletInfoDrag::AppletInfoDrag(const AppletInfo& info, TQWidget *dragSource)
+ : TQDragObject(dragSource, 0)
{
- QBuffer buff(a);
+ TQBuffer buff(a);
buff.open(IO_WriteOnly);
- QDataStream s(&buff);
+ TQDataStream s(&buff);
s << info.desktopFile() << info.configFile() << info.type();
}
@@ -136,17 +136,17 @@ const char * AppletInfoDrag::format(int i) const
return 0;
}
-QByteArray AppletInfoDrag::encodedData(const char* mimeType) const
+TQByteArray AppletInfoDrag::encodedData(const char* mimeType) const
{
- if (QString("application/appletinfo") == mimeType)
+ if (TQString("application/appletinfo") == mimeType)
{
return a;
}
- return QByteArray();
+ return TQByteArray();
}
-bool AppletInfoDrag::canDecode(const QMimeSource * e)
+bool AppletInfoDrag::canDecode(const TQMimeSource * e)
{
if (!e->provides("application/appletinfo"))
{
@@ -156,21 +156,21 @@ bool AppletInfoDrag::canDecode(const QMimeSource * e)
return true;
}
-bool AppletInfoDrag::decode(const QMimeSource* e, AppletInfo& container)
+bool AppletInfoDrag::decode(const TQMimeSource* e, AppletInfo& container)
{
- QByteArray a = e->encodedData("application/appletinfo");
+ TQByteArray a = e->encodedData("application/appletinfo");
if (a.isEmpty())
{
return false;
}
- QBuffer buff(a);
+ TQBuffer buff(a);
buff.open(IO_ReadOnly);
- QDataStream s(&buff);
+ TQDataStream s(&buff);
- QString desktopFile;
- QString configFile;
+ TQString desktopFile;
+ TQString configFile;
int type;
s >> desktopFile >> configFile >> type;
AppletInfo info(desktopFile, configFile, (AppletInfo::AppletType)type);