Initial TQt conversion

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/4/head
Slávek Banko 9 years ago
parent 77649eee77
commit 12348780ec

@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>appProp</class>
<widget class="QDialog">
<widget class="TQDialog">
<property name="name">
<cstring>appProp</cstring>
</property>
@ -45,7 +45,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QPushButton" row="2" column="2">
<widget class="TQPushButton" row="2" column="2">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@ -59,7 +59,7 @@
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" row="2" column="1">
<widget class="TQPushButton" row="2" column="1">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@ -93,7 +93,7 @@
</size>
</property>
</spacer>
<widget class="QGroupBox" row="1" column="0" rowspan="1" colspan="3">
<widget class="TQGroupBox" row="1" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@ -112,7 +112,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>terminal</cstring>
</property>
@ -120,7 +120,7 @@
<string>Run From Terminal</string>
</property>
</widget>
<widget class="QCheckBox" row="1" column="0">
<widget class="TQCheckBox" row="1" column="0">
<property name="name">
<cstring>cuser</cstring>
</property>
@ -128,7 +128,7 @@
<string>Run as different User</string>
</property>
</widget>
<widget class="QCheckBox" row="0" column="1">
<widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>tclose</cstring>
</property>
@ -136,14 +136,14 @@
<string>Keep terminal open after exit</string>
</property>
</widget>
<widget class="QLineEdit" row="1" column="1">
<widget class="TQLineEdit" row="1" column="1">
<property name="name">
<cstring>user</cstring>
</property>
</widget>
</grid>
</widget>
<widget class="QGroupBox" row="0" column="0" rowspan="1" colspan="3">
<widget class="TQGroupBox" row="0" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>groupBox2</cstring>
</property>
@ -162,7 +162,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0" rowspan="1" colspan="2">
<widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>textLabel3</cstring>
</property>
@ -170,7 +170,7 @@
<string>Don't forget to chose an icon.</string>
</property>
</widget>
<widget class="QLabel" row="2" column="0">
<widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@ -178,7 +178,7 @@
<string>&lt;b&gt;Command&lt;/b&gt;</string>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@ -186,7 +186,7 @@
<string>&lt;b&gt;Name&lt;/b&gt;</string>
</property>
</widget>
<widget class="QPushButton" row="2" column="2">
<widget class="TQPushButton" row="2" column="2">
<property name="name">
<cstring>cmdfile</cstring>
</property>
@ -205,12 +205,12 @@
<string>Icon</string>
</property>
</widget>
<widget class="QLineEdit" row="1" column="1">
<widget class="TQLineEdit" row="1" column="1">
<property name="name">
<cstring>cmdname</cstring>
</property>
</widget>
<widget class="QLineEdit" row="2" column="1">
<widget class="TQLineEdit" row="2" column="1">
<property name="name">
<cstring>cmdpath</cstring>
</property>

@ -19,7 +19,7 @@
#include "appProp.h"
#include "kooldock.h"
appPropPrg::appPropPrg(QWidget *parent, const char *name)
appPropPrg::appPropPrg(TQWidget *parent, const char *name)
: appProp(parent, name)
{
@ -32,10 +32,10 @@ appPropPrg::~appPropPrg()
void appPropPrg::accept()
{
QString icon;
QString desktop;
QString path;
QString puser;
TQString icon;
TQString desktop;
TQString path;
TQString puser;
icon=iconbutton->icon();
desktop=cmdname->text();
@ -70,14 +70,14 @@ void appPropPrg::accept()
desktop.append(".desktop");
//To handle position
QString progPath = locateLocal("data", "kooldock");
QDir dir(progPath + QString("/menu/"));
QString preffix;
QStringList fileList = dir.entryList("*.desktop");
TQString progPath = locateLocal("data", "kooldock");
TQDir dir(progPath + TQString("/menu/"));
TQString preffix;
TQStringList fileList = dir.entryList("*.desktop");
int pos=fileList.count();
if(pos<10) preffix=QString("0%1_").arg(pos);
if(pos>=10) preffix=QString("%1_").arg(pos);
if(pos<10) preffix=TQString("0%1_").arg(pos);
if(pos>=10) preffix=TQString("%1_").arg(pos);
desktop.prepend(preffix);
//End handling position
@ -103,7 +103,7 @@ void appPropPrg::reject()
this->hide();
}
void appPropPrg::closeEvent( QCloseEvent *e )
void appPropPrg::closeEvent( TQCloseEvent *e )
{
e->ignore();
reject();
@ -111,9 +111,9 @@ void appPropPrg::closeEvent( QCloseEvent *e )
void appPropPrg::cmdfile_clicked()
{
QString tmp;
TQString tmp;
QString fileToOpen=KFileDialog::getOpenFileName(QDir::currentDirPath(), "*.*", this, i18n("Open File"));
TQString fileToOpen=KFileDialog::getOpenFileName(TQDir::currentDirPath(), "*.*", this, i18n("Open File"));
if (!fileToOpen.isEmpty())
{
cmdpath->setText(fileToOpen);

@ -12,7 +12,7 @@
#ifndef APPPROPPRG_H
#define APPPROPPRG_H
#include <qwidget.h>
#include <ntqwidget.h>
#include "appProp.h"
/**
@ -24,13 +24,13 @@ class appPropPrg : public appProp
Q_OBJECT
public:
appPropPrg(QWidget *parent = 0, const char *name = 0);
appPropPrg(TQWidget *parent = 0, const char *name = 0);
~appPropPrg();
void addFile(const QString& filename,
const QString& iconname,
const QString& execname,
const QString& name,
void addFile(const TQString& filename,
const TQString& iconname,
const TQString& execname,
const TQString& name,
bool notify);
public slots:
@ -43,7 +43,7 @@ Q_OBJECT
void apply();
protected:
void closeEvent( QCloseEvent* );
void closeEvent( TQCloseEvent* );
};
#endif

@ -1,17 +1,17 @@
#include "clip.h"
#include <qwidget.h>
#include <qbitmap.h>
#include <qpainter.h>
#include <ntqwidget.h>
#include <ntqbitmap.h>
#include <ntqpainter.h>
#include <netwm.h>
#include <netwm_def.h>
#include <kwin.h>
#include <kdebug.h>
clip::clip(QWidget *parent, const char *name) : QWidget(parent, name, WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WDestructiveClose | WMouseNoMask | WStyle_StaysOnTop)
clip::clip(TQWidget *parent, const char *name) : TQWidget(parent, name, WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WDestructiveClose | WMouseNoMask | WStyle_StaysOnTop)
{
info = new NETWinInfo( qt_xdisplay(), winId(), qt_xrootwin(), NET::WMState);
info = new NETWinInfo( tqt_xdisplay(), winId(), tqt_xrootwin(), NET::WMState);
info->setDesktop( NETWinInfo::OnAllDesktops );
info->setState(NETWinInfo::SkipTaskbar | NETWinInfo::SkipPager, NETWinInfo::SkipTaskbar | NETWinInfo::SkipPager);
@ -34,13 +34,13 @@ void clip::clipDesktop(int p1,int p2,int p3,int p4,int p5,int p6,int p7,int p8,i
KWin::setExtendedStrut(winId(), p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12);
}
void clip::paintEvent(QPaintEvent *)
void clip::paintEvent(TQPaintEvent *)
{
QBitmap bm(size());
QPainter mp;
TQBitmap bm(size());
TQPainter mp;
mp.begin(&bm, this);
mp.fillRect(rect(), Qt::black);
mp.fillRect(rect(), TQt::black);
mp.end();
setMask(bm);

@ -5,16 +5,16 @@
#include <config.h>
#endif
#include <qwidget.h>
#include <ntqwidget.h>
#include <netwm.h>
#include <kwin.h>
class clip : public QWidget
class clip : public TQWidget
{
Q_OBJECT
public:
clip(QWidget* parent=0, const char *name=0);
clip(TQWidget* parent=0, const char *name=0);
virtual ~clip();
void clipDesktop(int,int,int,int,int,int,int,int,int,int,int,int);
@ -23,7 +23,7 @@ Q_OBJECT
NETWinInfo *info;
protected:
void paintEvent(QPaintEvent *);
void paintEvent(TQPaintEvent *);
};
#endif // CLIP_H_

@ -18,13 +18,13 @@
#include <kglobal.h>
#include <kicontheme.h>
#include <qfile.h>
#include <qimage.h>
#include <qtextstream.h>
#include <ntqfile.h>
#include <ntqimage.h>
#include <ntqtextstream.h>
#include "item.h"
Item::Item(const QString& iconName, const QString& cmd, const QString& name, int minSize, int maxSize) {
Item::Item(const TQString& iconName, const TQString& cmd, const TQString& name, int minSize, int maxSize) {
iLoader = KGlobal::iconLoader();
command = cmd;
this->name = name;
@ -36,7 +36,7 @@ Item::Item(const QString& iconName, const QString& cmd, const QString& name, int
this->maxSize = maxSize;
this->iconName = iconName;
QImage icon(iLoader->loadIcon(iconName, KIcon::NoGroup, 64).convertToImage());
TQImage icon(iLoader->loadIcon(iconName, KIcon::NoGroup, 64).convertToImage());
if (minSize <= maxSize)
{
int count = maxSize - minSize + 1;
@ -47,7 +47,7 @@ Item::Item(const QString& iconName, const QString& cmd, const QString& name, int
{
if (i % SIZE_INC == 0)
{
icons.append(new QPixmap(icon.smoothScale(minSize + i, minSize + i)));
icons.append(new TQPixmap(icon.smoothScale(minSize + i, minSize + i)));
}
}
}
@ -57,10 +57,10 @@ Item::Item(const QString& iconName, const QString& cmd, const QString& name, int
}
Item::Item(const QString& fileName, int minSize, int maxSize)
Item::Item(const TQString& fileName, int minSize, int maxSize)
{
QString line;
QFile in(fileName);
TQString line;
TQFile in(fileName);
in.open(IO_ReadOnly);
mCount=0;
mIndex=0;
@ -98,7 +98,7 @@ Item::Item(const QString& fileName, int minSize, int maxSize)
mIndex=0;
mMIndex=0;
mClass="";
QImage icon(iLoader->loadIcon(iconName, KIcon::NoGroup, 64).convertToImage());
TQImage icon(iLoader->loadIcon(iconName, KIcon::NoGroup, 64).convertToImage());
if (minSize <= maxSize)
{
int count = maxSize - minSize + 1;
@ -109,7 +109,7 @@ Item::Item(const QString& fileName, int minSize, int maxSize)
{
if (i % SIZE_INC == 0)
{
icons.append(new QPixmap(icon.smoothScale(minSize + i, minSize + i)));
icons.append(new TQPixmap(icon.smoothScale(minSize + i, minSize + i)));
}
}
}
@ -118,7 +118,7 @@ Item::Item(const QString& fileName, int minSize, int maxSize)
animed = FALSE;
}
Item::Item(const QPixmap& iconBig, WId id, const QString& name, int minSize, int maxSize, bool wi)
Item::Item(const TQPixmap& iconBig, WId id, const TQString& name, int minSize, int maxSize, bool wi)
{
setId(id);
this->name = name;
@ -130,7 +130,7 @@ Item::Item(const QPixmap& iconBig, WId id, const QString& name, int minSize, int
this->maxSize = maxSize;
command = "";
wIcon=wi;
QImage icon(iconBig.convertToImage());
TQImage icon(iconBig.convertToImage());
if(minSize <= maxSize)
{
int count = maxSize - minSize + 1;
@ -142,10 +142,10 @@ Item::Item(const QPixmap& iconBig, WId id, const QString& name, int minSize, int
if (i % SIZE_INC == 0)
{
if (wi)
{icons.append(new QPixmap(icon));}
{icons.append(new TQPixmap(icon));}
else
{
icons.append(new QPixmap(icon.scale(minSize + i, minSize + i)));
icons.append(new TQPixmap(icon.scale(minSize + i, minSize + i)));
}
//moothS
}
@ -158,14 +158,14 @@ Item::~Item()
{
}
QPixmap* Item::getIcon(int size)
TQPixmap* Item::getIcon(int size)
{
if ((size >= minSize) && (size <= maxSize))
{
int d = size - minSize;
return(icons.at(d / SIZE_INC));
//return(new QPixmap (icons.at(maxSize-minSize)->convertToImage().scale(size,size)));
//return(new TQPixmap (icons.at(maxSize-minSize)->convertToImage().scale(size,size)));
}
else
{
@ -173,17 +173,17 @@ QPixmap* Item::getIcon(int size)
}
}
QString Item::getCommand()
TQString Item::getCommand()
{
return(command);
}
QString Item::getName()
TQString Item::getName()
{
return(name);
}
QCString Item::getClass()
TQCString Item::getClass()
{
return(mClass);
}
@ -203,7 +203,7 @@ int Item::getMIndex()
return(mMIndex);
}
QString Item::getFilename()
TQString Item::getFilename()
{
return(filename);
}
@ -220,10 +220,10 @@ void Item::setId(WId newId)
id=newId;
}
void Item::setIcon(const QPixmap& iconBig)
void Item::setIcon(const TQPixmap& iconBig)
{
icons.clear();
QImage icon(iconBig.convertToImage());
TQImage icon(iconBig.convertToImage());
int count = maxSize - minSize + 1;
@ -233,17 +233,17 @@ void Item::setIcon(const QPixmap& iconBig)
{
if (i % SIZE_INC == 0)
{
icons.append(new QPixmap(icon.smoothScale(minSize + i, minSize + i)));
icons.append(new TQPixmap(icon.smoothScale(minSize + i, minSize + i)));
}
}
}
void Item::setName(const QString& newName)
void Item::setName(const TQString& newName)
{
name = newName;
}
void Item::setClass(const QCString& newClass)
void Item::setClass(const TQCString& newClass)
{
mClass = newClass;
}

@ -21,13 +21,13 @@
#include <kiconloader.h>
#include <kwin.h>
#include <qstring.h>
#include <qpixmap.h>
#include <qptrlist.h>
#include <ntqstring.h>
#include <ntqpixmap.h>
#include <ntqptrlist.h>
#include <vector>
#include <qevent.h>
#include <qnamespace.h>
#include <ntqevent.h>
#include <ntqnamespace.h>
const int MAX_LEN = 256;
const int SIZE_INC = 1;
@ -35,34 +35,34 @@ const int SIZE_INC = 1;
class Item
{
public:
Item(const QString& iconName, const QString& cmd, const QString& name, int minSize, int maxSize);
Item(const QString& fileName, int minSize, int maxSize);
Item(const QPixmap& iconBig, WId id, const QString& name, int minSize, int maxSize, bool wi =FALSE);
Item(const TQString& iconName, const TQString& cmd, const TQString& name, int minSize, int maxSize);
Item(const TQString& fileName, int minSize, int maxSize);
Item(const TQPixmap& iconBig, WId id, const TQString& name, int minSize, int maxSize, bool wi =FALSE);
~Item();
void setIcon(const QPixmap& iconBig);
void setIcon(const TQPixmap& iconBig);
QPixmap* getIcon(int size);
QString getCommand();
QString getName();
QCString getClass();
TQPixmap* getIcon(int size);
TQString getCommand();
TQString getName();
TQCString getClass();
int getCount();
int getIndex();
int getMIndex();
WId getId();
KWin::WindowInfo info;
void setId(WId newId);
QString getFilename();
TQString getFilename();
void setName(const QString& newName);
void setClass(const QCString& newClass);
void setName(const TQString& newName);
void setClass(const TQCString& newClass);
void setCount(int newCount);
void setIndex(int newIndex);
void setMIndex(int newIndex);
bool animed;
bool isAnimed();
void anim(bool param);
QPtrList<QPixmap> icons;
TQPtrList<TQPixmap> icons;
bool wIcon;
private:
@ -70,14 +70,14 @@ class Item
int minSize;
int maxSize;
QString command;
QString name;
QCString mClass;
TQString command;
TQString name;
TQCString mClass;
int mCount;
int mIndex;
int mMIndex;
QString iconName;
QString filename;
TQString iconName;
TQString filename;
WId id;
};

File diff suppressed because it is too large Load Diff

@ -30,14 +30,14 @@
#include <kpixmap.h>
#include <kurifilter.h>
#include <qwidget.h>
#include <qptrlist.h>
#include <qtimer.h>
#include <qcolor.h>
#include <ntqwidget.h>
#include <ntqptrlist.h>
#include <ntqtimer.h>
#include <ntqcolor.h>
#include <netwm.h>
#include <qdatetime.h>
#include <ntqdatetime.h>
#include "item.h"
#include "xosd.h"
@ -59,22 +59,22 @@ const int SPACE_W = 1; // space between quick launchers and tasks (the seperator
const int ON_CHANGE_ANIM_INTERVAL = 50; // animation's interval
/** KoolDock is the base class of the project */
class KoolDock : public QWidget
class KoolDock : public TQWidget
{
Q_OBJECT
public:
/** construtor */
KoolDock(QWidget* parent=0, const char *name=0);
KoolDock(TQWidget* parent=0, const char *name=0);
/** destructor */
~KoolDock();
//static bool writeIgnoreList(QString text);
void setMainPath(const QString& path);
void setArgs(const QString& param);
//static bool writeIgnoreList(TQString text);
void setMainPath(const TQString& path);
void setArgs(const TQString& param);
clip *clipw;
private:
QTime *perf;
TQTime *perf;
// configuration variables
int fShowTaskbar; // show-taskbar flag
int fMinimizedOnly; // show only minimized icons flag
@ -90,7 +90,7 @@ class KoolDock : public QWidget
int zoomTicksB, zoomTicksS; //counts timer ticks
int neededTicksB,neededTicksS; //sets how many ticks is necessary to calculate new speed
bool fSpeed;
QColor borderColor;
TQColor borderColor;
int fHidden; // hidden dockbar
int fStayBelow;
int fOrientation; //bottom/left/top/right
@ -112,7 +112,7 @@ class KoolDock : public QWidget
int fCurrent; //whether to only show windows on current desktop
int oldDesktop; //number of previous desktop
bool firstTime; //to control certain things
QString curTheme; //for the background theme (to preserve changes)
TQString curTheme; //for the background theme (to preserve changes)
int leftRes; //Left monitor resolution
int XinDesiredHeight;
int XinPreviousWidth;
@ -125,24 +125,24 @@ class KoolDock : public QWidget
int ptPart;
bool mouseOnLauncher;
QStringList lstDrop;
TQStringList lstDrop;
bool useList;
Atom net_system_tray_selection;
Atom net_system_tray_opcode;
QString fLeftImg;
QString fRightImg;
QString fCenterImg;
TQString fLeftImg;
TQString fRightImg;
TQString fCenterImg;
bool fNWideBg;
bool scaleMax;
QPixmap LeftImg;
QPixmap RightImg;
QPixmap CenterImg;
QPixmap TempScaledCenter;
QPixmap TestPix;
QImage TestIm;
TQPixmap LeftImg;
TQPixmap RightImg;
TQPixmap CenterImg;
TQPixmap TempScaledCenter;
TQPixmap TestPix;
TQImage TestIm;
unsigned int oLeft, oRight;
@ -155,22 +155,22 @@ class KoolDock : public QWidget
int lastX;
int dockOpacity;
QColor bgColor;
TQColor bgColor;
QColor sepColor; // separator bar's color
TQColor sepColor; // separator bar's color
int Ybase;
// normal variables
QString progPath;
QString menuPath;
QString confFile;
QString iFilename; // right clicked item filename
QString mainPath;
QString args;
TQString progPath;
TQString menuPath;
TQString confFile;
TQString iFilename; // right clicked item filename
TQString mainPath;
TQString args;
QStringList ignoreList;
TQStringList ignoreList;
NETWinInfo *info;
@ -192,29 +192,29 @@ class KoolDock : public QWidget
int last_mx;
int last_ncx;
QPtrList<Item> items;//currently visible items
QPtrList<Item> witems;//all windows on all desktops
TQPtrList<Item> items;//currently visible items
TQPtrList<Item> witems;//all windows on all desktops
int iSize[MAX_ICONS + 1];//icon sizes
int cx[MAX_ICONS + 1];//positions of small icons
int cur_cx[MAX_ICONS + 1];//positions of visible icons
QPixmap offscr;//drawing buffer
TQPixmap offscr;//drawing buffer
KRootPixmap *rootpix;
KPixmap bottomBg;
KPixmap bottomBgf;
QPixmap topBg;
TQPixmap topBg;
KAboutDialog *aboutDlg;
QTimer *mkbigTimer; //zoom animation timers
QTimer *mksmallTimer;
QTimer *mTimer; //mouse move emulator (can't use normal event instead)
QTimer *onChangeTimer; // used when a window has changed and we need to notify user
QTimer *trackTimer; //checks whether mouse touches screen edge
TQTimer *mkbigTimer; //zoom animation timers
TQTimer *mksmallTimer;
TQTimer *mTimer; //mouse move emulator (can't use normal event instead)
TQTimer *onChangeTimer; // used when a window has changed and we need to notify user
TQTimer *trackTimer; //checks whether mouse touches screen edge
int animStep; // animation step, not in use yet
int iOnClick; // index of the quick launcher being clicked
WId cId; // id of the application (used in the right click menu over the taskbar)
QString cClass;
TQString cClass;
WId CurrentFocus;
int onChangeAnimStep;
KPopupMenu *deskpopup;
@ -225,24 +225,24 @@ class KoolDock : public QWidget
KPopupMenu *advMenu;
int menuCount, currMenu;
bool allApps;
QPtrList<KPopupMenu> popups;
TQPtrList<KPopupMenu> popups;
bool iGroup;
int dIndex, nDesks;
QPtrList<dInfo> desks;
TQPtrList<dInfo> desks;
bool fExpanded;
bool track2active;
/*Xosd Section */
QString nom;
QString aux;
TQString nom;
TQString aux;
//xosd *osd;
int xosd_st;
int showNames;
int fCleaner;
int xosdShadowOffset;
QString xosdFont;
QString xosdColor;
QString xosdShadowColor;
TQString xosdFont;
TQString xosdColor;
TQString xosdShadowColor;
bool xosdBold;
bool xosdItalic;
int xosdSize;
@ -251,7 +251,7 @@ class KoolDock : public QWidget
int animValue;
int animState;
void run(const QString& cmd);
void run(const TQString& cmd);
int func(int x);
int func2(int x);
void doUpdateGeometry();
@ -279,16 +279,16 @@ class KoolDock : public QWidget
void init2();
protected:
void paintEvent(QPaintEvent *);
void mousePressEvent( QMouseEvent * );
void paintEvent(TQPaintEvent *);
void mousePressEvent( TQMouseEvent * );
void mMoveEvent( int ex, int ey);
void mPress( int mx, int my, ButtonState srcButton);
void wheelEvent(QWheelEvent *);
void enterEvent(QEvent*);
void onleaveEvent(QEvent*);
void wheelEvent(TQWheelEvent *);
void enterEvent(TQEvent*);
void onleaveEvent(TQEvent*);
void mksmallTimerstop();
void dragMoveEvent(QDragMoveEvent* event);
void dropEvent(QDropEvent* event);
void dragMoveEvent(TQDragMoveEvent* event);
void dropEvent(TQDropEvent* event);
public slots:
void edit();
@ -301,7 +301,7 @@ class KoolDock : public QWidget
void workAreaChanged();
void currentDesktopChanged(int);
void onChangeTimerTicked();
void updateBackground(const QPixmap&);
void updateBackground(const TQPixmap&);
void moveApp();
void resizeApp();
void minApp();
@ -329,22 +329,22 @@ class KoolDock : public QWidget
void toggleKeptBelowOthers();
void toggleFullScreen();
static void addFile(const QString& filename,
const QString& iconname,
const QString& execname,
const QString& name,
static void addFile(const TQString& filename,
const TQString& iconname,
const TQString& execname,
const TQString& name,
bool notify = true,
bool terminal = false,
bool tclose = false,
bool cuser = false,
QString = "na");
bool ignored(const QString& appname);
TQString = "na");
bool ignored(const TQString& appname);
#ifdef _ENABLE_DEBUG
static void debug(QString message);
static void debug(TQString message);
#endif
#ifndef _ENABLE_DEBUG
static void debug(QString);
static void debug(TQString);
#endif
void mkbigTimerDo();
void mksmallTimerDo();

@ -29,7 +29,7 @@
#include "kooldock.h"
#define KOOLDOCK_VERSION "0.4.7"
QString argv0;
TQString argv0;
#ifndef _ENABLE_DEBUG
extern "C"
@ -57,7 +57,7 @@ static KCmdLineOptions options[] =
int main(int argc, char *argv[])
{
argv0=QString("%1").arg(argv[0]);
argv0=TQString("%1").arg(argv[0]);
KAboutData aboutData( "kooldock", I18N_NOOP("KoolDock"),
KOOLDOCK_VERSION, description, KAboutData::License_GPL,
@ -77,7 +77,7 @@ int main(int argc, char *argv[])
#ifndef _ENABLE_DEBUG
KUniqueApplication::addCmdLineOptions();
#endif
if (QString("%1").arg(argv[1])=="-kill" || QString("%1").arg(argv[1])=="-k")
if (TQString("%1").arg(argv[1])=="-kill" || TQString("%1").arg(argv[1])=="-k")
{
system("killall kooldock");
exit(0);
@ -109,6 +109,6 @@ int main(int argc, char *argv[])
#endif
kooldock->setMainPath(argv0);
kooldock->setArgs(QString("%1").arg(argv[1]));
kooldock->setArgs(TQString("%1").arg(argv[1]));
return a.exec();
}

@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>SetupDialog</class>
<widget class="QDialog">
<widget class="TQDialog">
<property name="name">
<cstring>SetupDialog</cstring>
</property>
@ -49,7 +49,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QPushButton" row="1" column="3">
<widget class="TQPushButton" row="1" column="3">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@ -63,7 +63,7 @@
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" row="1" column="2">
<widget class="TQPushButton" row="1" column="2">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@ -80,7 +80,7 @@
<bool>true</bool>
</property>
</widget>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>toReloadIcons</cstring>
</property>
@ -94,7 +94,7 @@
<string>checkBox11</string>
</property>
</widget>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>systray</cstring>
</property>
@ -122,11 +122,11 @@
<string>Enables KoolDock System Tray Support; it can be used instead of kicker's systray applet (its VERY experimental; do not use it unless you intend to help me get this working :P )</string>
</property>
</widget>
<widget class="QTabWidget" row="0" column="0" rowspan="1" colspan="4">
<widget class="TQTabWidget" row="0" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>tabWidget</cstring>
</property>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>Widget2</cstring>
</property>
@ -137,7 +137,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox3</cstring>
</property>
@ -198,7 +198,7 @@
<enum>Horizontal</enum>
</property>
</widget>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>chk1</cstring>
</property>
@ -212,7 +212,7 @@
<string>Start KoolDock hidden; if the mouse is not over KoolDock it will hide</string>
</property>
</widget>
<widget class="QCheckBox" row="3" column="0">
<widget class="TQCheckBox" row="3" column="0">
<property name="name">
<cstring>chk5</cstring>
</property>
@ -223,7 +223,7 @@
<string>Enables KoolDock taskbar; it can be used instead of Kicker's taskbar</string>
</property>
</widget>
<widget class="QCheckBox" row="4" column="0">
<widget class="TQCheckBox" row="4" column="0">
<property name="name">
<cstring>chk6</cstring>
</property>
@ -234,7 +234,7 @@
<string>Window icon in KoolDock's taskbar will blink when something happens on the given application</string>
</property>
</widget>
<widget class="QCheckBox" row="5" column="0">
<widget class="TQCheckBox" row="5" column="0">
<property name="name">
<cstring>chkGrouping</cstring>
</property>
@ -245,7 +245,7 @@
<string>Enables grouping similar task icons into one icon.</string>
</property>
</widget>
<widget class="QCheckBox" row="7" column="0">
<widget class="TQCheckBox" row="7" column="0">
<property name="name">
<cstring>chk7</cstring>
</property>
@ -256,7 +256,7 @@
<string>Shows the KDE Menu in KoolDock's launcher.</string>
</property>
</widget>
<widget class="QCheckBox" row="9" column="0" rowspan="1" colspan="2">
<widget class="TQCheckBox" row="9" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Steppy</cstring>
</property>
@ -267,7 +267,7 @@
<string>Makes the scrolling not smooth, but automatically centered on current icon.</string>
</property>
</widget>
<widget class="QCheckBox" row="10" column="0" rowspan="1" colspan="2">
<widget class="TQCheckBox" row="10" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>nav</cstring>
</property>
@ -278,7 +278,7 @@
<string>Adds a clock into the Main Menu and a virtual desktop navigator.</string>
</property>
</widget>
<widget class="QCheckBox" row="7" column="1">
<widget class="TQCheckBox" row="7" column="1">
<property name="name">
<cstring>chkUseKBFX</cstring>
</property>
@ -289,7 +289,7 @@
<string>Makes that KoolDock don't use KMenu, but uses alternative KBFX menu (widget is necessary).</string>
</property>
</widget>
<widget class="QCheckBox" row="5" column="1">
<widget class="TQCheckBox" row="5" column="1">
<property name="name">
<cstring>cbMinimizedOnly</cstring>
</property>
@ -300,7 +300,7 @@
<string>That makes kooldock shows only the minimized application icons, and hides the other.</string>
</property>
</widget>
<widget class="QCheckBox" row="4" column="1">
<widget class="TQCheckBox" row="4" column="1">
<property name="name">
<cstring>chkSshot</cstring>
</property>
@ -311,7 +311,7 @@
<string>When a window is minimized a screenshot of the application will be use as an icon in KoolDock's Taskbar.</string>
</property>
</widget>
<widget class="QCheckBox" row="3" column="1">
<widget class="TQCheckBox" row="3" column="1">
<property name="name">
<cstring>currentDesk</cstring>
</property>
@ -322,7 +322,7 @@
<string>Only show in KoolDock's taskbar windows in the current desktop</string>
</property>
</widget>
<widget class="QCheckBox" row="0" column="1">
<widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>hideOnClick</cstring>
</property>
@ -344,7 +344,7 @@
<string>Hide KoolDock after clicking on a Launcher or Window icon.</string>
</property>
</widget>
<widget class="QCheckBox" row="1" column="0" rowspan="1" colspan="2">
<widget class="TQCheckBox" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>cbStayBelow</cstring>
</property>
@ -359,7 +359,7 @@
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -370,7 +370,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox10</cstring>
</property>
@ -381,7 +381,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="2" column="0">
<widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>textLabel1_4</cstring>
</property>
@ -394,7 +394,7 @@
<cstring>xosdFont</cstring>
</property>
</widget>
<widget class="QLabel" row="5" column="0">
<widget class="TQLabel" row="5" column="0">
<property name="name">
<cstring>textLabel1_2</cstring>
</property>
@ -402,7 +402,7 @@
<string>Shadow offset:</string>
</property>
</widget>
<widget class="QSpinBox" row="5" column="1">
<widget class="TQSpinBox" row="5" column="1">
<property name="name">
<cstring>spinBox2</cstring>
</property>
@ -413,7 +413,7 @@
<number>0</number>
</property>
</widget>
<widget class="QLabel" row="4" column="0">
<widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@ -426,7 +426,7 @@
<cstring>kColorCombo1</cstring>
</property>
</widget>
<widget class="QSpinBox" row="3" column="1">
<widget class="TQSpinBox" row="3" column="1">
<property name="name">
<cstring>xosdSize</cstring>
</property>
@ -437,7 +437,7 @@
<number>1</number>
</property>
</widget>
<widget class="QLabel" row="3" column="0">
<widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>textLabel1_2_2</cstring>
</property>
@ -450,7 +450,7 @@
<cstring>kColorCombo_shadow</cstring>
</property>
</widget>
<widget class="QLabel" row="6" column="0">
<widget class="TQLabel" row="6" column="0">
<property name="name">
<cstring>textLabel1_8</cstring>
</property>
@ -472,7 +472,7 @@
<enum>Horizontal</enum>
</property>
</widget>
<widget class="QCheckBox" row="7" column="0" rowspan="1" colspan="2">
<widget class="TQCheckBox" row="7" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>cbCleaner</cstring>
</property>
@ -480,7 +480,7 @@
<string>Cleaner text (bigger memory and CPU usage)</string>
</property>
</widget>
<widget class="QFrame" row="0" column="0" rowspan="1" colspan="2">
<widget class="TQFrame" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>frame3</cstring>
</property>
@ -505,7 +505,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QCheckBox" row="0" column="2">
<widget class="TQCheckBox" row="0" column="2">
<property name="name">
<cstring>xosdBold</cstring>
</property>
@ -533,7 +533,7 @@
</size>
</property>
</spacer>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>chk2</cstring>
</property>
@ -561,7 +561,7 @@
</size>
</property>
</spacer>
<widget class="QCheckBox" row="0" column="4">
<widget class="TQCheckBox" row="0" column="4">
<property name="name">
<cstring>xosdItalic</cstring>
</property>
@ -595,7 +595,7 @@
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -606,7 +606,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox9</cstring>
</property>
@ -617,7 +617,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0">
<widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@ -625,12 +625,12 @@
<string>Small icon size:</string>
</property>
</widget>
<widget class="QSpinBox" row="0" column="1">
<widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>iwSmall</cstring>
</property>
</widget>
<widget class="QLabel" row="0" column="2">
<widget class="TQLabel" row="0" column="2">
<property name="name">
<cstring>textLabel2_2</cstring>
</property>
@ -638,7 +638,7 @@
<string>Big icon size:</string>
</property>
</widget>
<widget class="QSpinBox" row="0" column="3">
<widget class="TQSpinBox" row="0" column="3">
<property name="name">
<cstring>iwBig</cstring>
</property>
@ -646,7 +646,7 @@
<number>160</number>
</property>
</widget>
<widget class="QLabel" row="1" column="0" rowspan="1" colspan="2">
<widget class="TQLabel" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>textLabel1_13</cstring>
</property>
@ -662,7 +662,7 @@
<string>Amount of big icons:</string>
</property>
</widget>
<widget class="QSpinBox" row="1" column="2" rowspan="1" colspan="2">
<widget class="TQSpinBox" row="1" column="2" rowspan="1" colspan="2">
<property name="name">
<cstring>fAmount</cstring>
</property>
@ -676,7 +676,7 @@
<string>This box determines amout of zoomed icons.</string>
</property>
</widget>
<widget class="QLabel" row="2" column="0" rowspan="1" colspan="2">
<widget class="TQLabel" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>textLabel1_6</cstring>
</property>
@ -684,7 +684,7 @@
<string>Space between icons</string>
</property>
</widget>
<widget class="QSpinBox" row="2" column="2" rowspan="1" colspan="2">
<widget class="TQSpinBox" row="2" column="2" rowspan="1" colspan="2">
<property name="name">
<cstring>sbSpace</cstring>
</property>
@ -693,7 +693,7 @@
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -704,7 +704,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0" rowspan="1" colspan="2">
<widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>textLabel1_3</cstring>
</property>
@ -720,7 +720,7 @@
<string>Drag an application to add it or</string>
</property>
</widget>
<widget class="QPushButton" row="0" column="2" rowspan="1" colspan="2">
<widget class="TQPushButton" row="0" column="2" rowspan="1" colspan="2">
<property name="name">
<cstring>buttonadd</cstring>
</property>
@ -761,7 +761,7 @@
<string>Drag and Drop here any executable or desktop file for which you want an entry in KoolDock's Launcher</string>
</property>
</widget>
<widget class="QPushButton" row="2" column="0">
<widget class="TQPushButton" row="2" column="0">
<property name="name">
<cstring>mLeft</cstring>
</property>
@ -780,7 +780,7 @@
<string>Moves selected item left</string>
</property>
</widget>
<widget class="QPushButton" row="2" column="3">
<widget class="TQPushButton" row="2" column="3">
<property name="name">
<cstring>mRight</cstring>
</property>
@ -816,7 +816,7 @@
</size>
</property>
</spacer>
<widget class="QLabel" row="3" column="0" rowspan="1" colspan="4">
<widget class="TQLabel" row="3" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>textLabel1_5</cstring>
</property>
@ -834,7 +834,7 @@
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -845,7 +845,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QPushButton" row="0" column="0">
<widget class="TQPushButton" row="0" column="0">
<property name="name">
<cstring>grabWin</cstring>
</property>
@ -856,7 +856,7 @@
<string>Click here to start grabbing windows names; click Add for each window you click on</string>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel1_7</cstring>
</property>
@ -890,7 +890,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -901,7 +901,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="1" column="0">
<widget class="TQGroupBox" row="1" column="0">
<property name="name">
<cstring>chkSolid</cstring>
</property>
@ -923,7 +923,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="3" column="0">
<widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>textLabel1_3_2_2</cstring>
</property>
@ -936,7 +936,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<cstring>kColorCombo3</cstring>
</property>
</widget>
<widget class="QLabel" row="4" column="0">
<widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>textLabel1_3_3</cstring>
</property>
@ -944,7 +944,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Dock opacity:</string>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel1_3_2</cstring>
</property>
@ -957,7 +957,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<cstring>kColorCombo2</cstring>
</property>
</widget>
<widget class="QCheckBox" row="2" column="0">
<widget class="TQCheckBox" row="2" column="0">
<property name="name">
<cstring>chk4</cstring>
</property>
@ -968,7 +968,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>When using a Solid Background you may tell KoolDock to draw its borders (rectangle)</string>
</property>
</widget>
<widget class="QSpinBox" row="4" column="1">
<widget class="TQSpinBox" row="4" column="1">
<property name="name">
<cstring>spinBox1</cstring>
</property>
@ -984,7 +984,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox6</cstring>
</property>
@ -1031,7 +1031,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>The separator is a line drawed between KoolDock's Launcher and Taskbar</string>
</property>
</widget>
<widget class="QLabel" row="0" column="0">
<widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel1_3_2_2_2</cstring>
</property>
@ -1049,7 +1049,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QGroupBox" row="2" column="0">
<widget class="TQGroupBox" row="2" column="0">
<property name="name">
<cstring>chkImg</cstring>
</property>
@ -1077,7 +1077,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QCheckBox" row="2" column="0" rowspan="1" colspan="2">
<widget class="TQCheckBox" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>nWideBg</cstring>
</property>
@ -1088,7 +1088,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Mkaes that the background ends don't go over the screen edges.</string>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel1_9</cstring>
</property>
@ -1104,7 +1104,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Background Theme:</string>
</property>
</widget>
<widget class="QComboBox" row="1" column="1">
<widget class="TQComboBox" row="1" column="1">
<property name="name">
<cstring>theme</cstring>
</property>
@ -1117,7 +1117,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</sizepolicy>
</property>
</widget>
<widget class="QButtonGroup" row="3" column="0" rowspan="1" colspan="2">
<widget class="TQButtonGroup" row="3" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>buttonGroup2_2</cstring>
</property>
@ -1160,7 +1160,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QRadioButton" row="0" column="0">
<widget class="TQRadioButton" row="0" column="0">
<property name="name">
<cstring>opScale1</cstring>
</property>
@ -1193,7 +1193,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</size>
</property>
</spacer>
<widget class="QRadioButton" row="0" column="2">
<widget class="TQRadioButton" row="0" column="2">
<property name="name">
<cstring>opScale2</cstring>
</property>
@ -1232,7 +1232,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -1243,7 +1243,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox5</cstring>
</property>
@ -1262,7 +1262,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0">
<widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel1_11</cstring>
</property>
@ -1270,7 +1270,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Window position on edge (%):</string>
</property>
</widget>
<widget class="QSpinBox" row="0" column="1">
<widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>percentPos</cstring>
</property>
@ -1287,7 +1287,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Determines the position of expanded KoolDock's window on the selected screen edge.</string>
</property>
</widget>
<widget class="QCheckBox" row="2" column="0">
<widget class="TQCheckBox" row="2" column="0">
<property name="name">
<cstring>xrma</cstring>
</property>
@ -1315,7 +1315,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<enum>Horizontal</enum>
</property>
</widget>
<widget class="QLabel" row="3" column="0">
<widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>textLabel1_10</cstring>
</property>
@ -1323,7 +1323,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Desired Monitor Width</string>
</property>
</widget>
<widget class="QLabel" row="4" column="0">
<widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>textLabel1_12</cstring>
</property>
@ -1331,7 +1331,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Desired Monitor Height</string>
</property>
</widget>
<widget class="QSpinBox" row="3" column="1">
<widget class="TQSpinBox" row="3" column="1">
<property name="name">
<cstring>SleftRes</cstring>
</property>
@ -1348,7 +1348,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Width of monitor on which KoolDock should be shown.</string>
</property>
</widget>
<widget class="QSpinBox" row="4" column="1">
<widget class="TQSpinBox" row="4" column="1">
<property name="name">
<cstring>SHeight</cstring>
</property>
@ -1362,7 +1362,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Height of monitor on which kooldock should be shown.</string>
</property>
</widget>
<widget class="QSpinBox" row="5" column="1">
<widget class="TQSpinBox" row="5" column="1">
<property name="name">
<cstring>PWidth</cstring>
</property>
@ -1373,7 +1373,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Sum of widths of monitors before the desired one.</string>
</property>
</widget>
<widget class="QLabel" row="5" column="0">
<widget class="TQLabel" row="5" column="0">
<property name="name">
<cstring>textLabel2_4</cstring>
</property>
@ -1381,7 +1381,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Previous Monitors Width</string>
</property>
</widget>
<widget class="QLabel" row="6" column="0">
<widget class="TQLabel" row="6" column="0">
<property name="name">
<cstring>textLabel2_5</cstring>
</property>
@ -1389,7 +1389,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Window position:</string>
</property>
</widget>
<widget class="QButtonGroup" row="6" column="1">
<widget class="TQButtonGroup" row="6" column="1">
<property name="name">
<cstring>buttonGroup2</cstring>
</property>
@ -1428,7 +1428,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</size>
</property>
</spacer>
<widget class="QRadioButton" row="1" column="0">
<widget class="TQRadioButton" row="1" column="0">
<property name="name">
<cstring>op3</cstring>
</property>
@ -1450,7 +1450,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Makes that KoolDock's window will appear on left screen edge.</string>
</property>
</widget>
<widget class="QRadioButton" row="1" column="2">
<widget class="TQRadioButton" row="1" column="2">
<property name="name">
<cstring>op1</cstring>
</property>
@ -1506,7 +1506,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</size>
</property>
</spacer>
<widget class="QRadioButton" row="0" column="1">
<widget class="TQRadioButton" row="0" column="1">
<property name="name">
<cstring>op2</cstring>
</property>
@ -1528,7 +1528,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Makes that KoolDock's window will appear on top screen edge.</string>
</property>
</widget>
<widget class="QRadioButton" row="2" column="1">
<widget class="TQRadioButton" row="2" column="1">
<property name="name">
<cstring>op0</cstring>
</property>
@ -1590,7 +1590,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QWidget">
<widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@ -1601,7 +1601,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QGroupBox" row="0" column="0">
<widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>groupBox7</cstring>
</property>
@ -1612,7 +1612,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0">
<widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel2_3</cstring>
</property>
@ -1620,7 +1620,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Priority (0=max, 19=min)</string>
</property>
</widget>
<widget class="QSpinBox" row="0" column="1">
<widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>Priority</cstring>
</property>
@ -1636,7 +1636,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QGroupBox" row="1" column="0">
<widget class="TQGroupBox" row="1" column="0">
<property name="name">
<cstring>groupBox8</cstring>
</property>
@ -1647,7 +1647,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QCheckBox" row="0" column="0">
<widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>chClipping</cstring>
</property>
@ -1658,7 +1658,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Makes desktop smaller that maximized windows don't cover KoolDock's window.</string>
</property>
</widget>
<widget class="QCheckBox" row="1" column="0">
<widget class="TQCheckBox" row="1" column="0">
<property name="name">
<cstring>chClipIcons</cstring>
</property>
@ -1671,7 +1671,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</widget>
</grid>
</widget>
<widget class="QGroupBox" row="2" column="0">
<widget class="TQGroupBox" row="2" column="0">
<property name="name">
<cstring>groupBox6_2</cstring>
</property>
@ -1682,7 +1682,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
<widget class="QLabel" row="0" column="0">
<widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>sejtanwodbycie</cstring>
</property>
@ -1690,7 +1690,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Zooming speed (ms)</string>
</property>
</widget>
<widget class="QSpinBox" row="0" column="1">
<widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>zoomSpeed</cstring>
</property>
@ -1722,7 +1722,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Determines the speen of zooming animation</string>
</property>
</widget>
<widget class="QLabel" row="1" column="0">
<widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel1_6_2</cstring>
</property>
@ -1730,7 +1730,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Show after</string>
</property>
</widget>
<widget class="QSpinBox" row="1" column="1">
<widget class="TQSpinBox" row="1" column="1">
<property name="name">
<cstring>hideTimer</cstring>
</property>
@ -1744,7 +1744,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<string>Time before showing KoolDock if mouse reaches bottom of the screen</string>
</property>
</widget>
<widget class="QCheckBox" row="2" column="0">
<widget class="TQCheckBox" row="2" column="0">
<property name="name">
<cstring>chkSpeed</cstring>
</property>
@ -1777,7 +1777,7 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</size>
</property>
</spacer>
<widget class="QPushButton" row="1" column="0">
<widget class="TQPushButton" row="1" column="0">
<property name="name">
<cstring>btnApply</cstring>
</property>
@ -1798,9 +1798,9 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<connections>
<connection>
<sender>applist</sender>
<signal>dropped(QDropEvent*,const QValueList&lt;QIconDragItem&gt;&amp;)</signal>
<signal>dropped(TQDropEvent*,const TQValueList&lt;TQIconDragItem&gt;&amp;)</signal>
<receiver>SetupDialog</receiver>
<slot>applist_dropped(QDropEvent*,const QValueList&lt;QIconDragItem&gt;&amp;)</slot>
<slot>applist_dropped(TQDropEvent*,const TQValueList&lt;TQIconDragItem&gt;&amp;)</slot>
</connection>
<connection>
<sender>buttonadd</sender>
@ -1828,9 +1828,9 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</connection>
<connection>
<sender>applist</sender>
<signal>contextMenuRequested(QIconViewItem*,const QPoint&amp;)</signal>
<signal>contextMenuRequested(TQIconViewItem*,const TQPoint&amp;)</signal>
<receiver>SetupDialog</receiver>
<slot>applist_contextMenuRequested(QIconViewItem*,const QPoint&amp;)</slot>
<slot>applist_contextMenuRequested(TQIconViewItem*,const TQPoint&amp;)</slot>
</connection>
<connection>
<sender>mLeft</sender>
@ -1846,9 +1846,9 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
</connection>
<connection>
<sender>applist</sender>
<signal>clicked(QIconViewItem*,const QPoint&amp;)</signal>
<signal>clicked(TQIconViewItem*,const TQPoint&amp;)</signal>
<receiver>SetupDialog</receiver>
<slot>applist_clicked(QIconViewItem*,const QPoint&amp;)</slot>
<slot>applist_clicked(TQIconViewItem*,const TQPoint&amp;)</slot>
</connection>
<connection>
<sender>xrma</sender>
@ -1951,8 +1951,8 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<slot>SelectLeftClicked()</slot>
<slot>SelectCenterClicked()</slot>
<slot>SelectRightClicked()</slot>
<slot>applist_dropped( QDropEvent *, const QValueList&lt;QIconDragItem&gt; &amp; )</slot>
<slot>applist_clicked( QIconViewItem *, const QPoint &amp; )</slot>
<slot>applist_dropped( TQDropEvent *, const TQValueList&lt;TQIconDragItem&gt; &amp; )</slot>
<slot>applist_clicked( TQIconViewItem *, const TQPoint &amp; )</slot>
<slot>buttonadd_clicked()</slot>
<slot>chk1_toggled( bool )</slot>
<slot>chkHidden( bool )</slot>
@ -1962,9 +1962,9 @@ box below. To stop grabbing just click "Grabbing...", "Ok" or "Cancel".</string>
<slot>chkFont()</slot>
<slot>chkTask()</slot>
<slot>grabWin_clicked()</slot>
<slot>applist_contextMenuRequested( QIconViewItem *, const QPoint &amp; )</slot>
<slot>applist_contextMenuRequested( TQIconViewItem *, const TQPoint &amp; )</slot>
<slot>xrma_clicked()</slot>
<slot>groupBox7_destroyed( QObject * )</slot>
<slot>groupBox7_destroyed( TQObject * )</slot>
<slot>left()</slot>
<slot>right()</slot>
<slot>configApply()</slot>

@ -19,13 +19,13 @@
#include <kpushbutton.h>
#include <keditlistbox.h>
#include <klineedit.h>
#include <qlistbox.h>
#include <ntqlistbox.h>
#include <krun.h>
#include <qiconview.h>
#include <qdir.h>
#include <qstringlist.h>
#include <qtabwidget.h>
#include <ntqiconview.h>
#include <ntqdir.h>
#include <ntqstringlist.h>
#include <ntqtabwidget.h>
#include "setupdialog.h"
#include "setupdialogprg.h"
@ -33,7 +33,7 @@
#include "appProp.h"
#include "kooldock.h"
SetupDialogPrg::SetupDialogPrg(QWidget *parent, const char *name)
SetupDialogPrg::SetupDialogPrg(TQWidget *parent, const char *name)
: SetupDialog(parent, name)
{
//Ignore list handlers
@ -51,7 +51,7 @@ SetupDialogPrg::SetupDialogPrg(QWidget *parent, const char *name)
// some configuration variables
progPath = locateLocal("data", "kooldock");
menuPath = progPath + QString("/menu/");
menuPath = progPath + TQString("/menu/");
KConfig *config = KGlobal::config();
config->setGroup("kooldock");
@ -66,12 +66,12 @@ SetupDialogPrg::SetupDialogPrg(QWidget *parent, const char *name)
//Lets load the theme List
KStandardDirs sys;
QStringList bgPath = sys.findDirs("data", "kooldock/backgrounds");
TQStringList bgPath = sys.findDirs("data", "kooldock/backgrounds");
for(unsigned int i=0; i<bgPath.count();i++)
{
QDir tmpdir(bgPath[i]);
QStringList theme_tmp(tmpdir.entryList(QDir::Dirs, QDir::Name));
//We do it like this to avoid showing "." and ".." instead of copying QDir::entryList directly into "theme"
TQDir tmpdir(bgPath[i]);
TQStringList theme_tmp(tmpdir.entryList(TQDir::Dirs, TQDir::Name));
//We do it like this to avoid showing "." and ".." instead of copying TQDir::entryList directly into "theme"
for(unsigned int j=2; j<theme_tmp.count(); j++) theme->insertItem(theme_tmp[j]);
}
}
@ -235,13 +235,13 @@ void SetupDialogPrg::configApply()
{
//Lets find exactly where the selected theme is
KStandardDirs sys;
QString theme_dir="kooldock/backgrounds/"+theme->currentText();
QStringList bgPath = sys.findDirs("data", theme_dir);
TQString theme_dir="kooldock/backgrounds/"+theme->currentText();
TQStringList bgPath = sys.findDirs("data", theme_dir);
//Lets set the images and write the config
QString LeftImg=(QString)bgPath[0]+"background-left.png";
QString CenterImg=(QString)bgPath[0]+"background-center.png";
QString RightImg=(QString)bgPath[0]+"background-right.png";
TQString LeftImg=(TQString)bgPath[0]+"background-left.png";
TQString CenterImg=(TQString)bgPath[0]+"background-center.png";
TQString RightImg=(TQString)bgPath[0]+"background-right.png";
// background image enabled
config->writeEntry("Solid", 0);
@ -267,15 +267,15 @@ void SetupDialogPrg::configApply()
config->sync();
// write ignore list to file
QString progPath = locateLocal("data", "kooldock");
QString menuPath = progPath + QString("/menu/");
filepath = QString(progPath + "/ignorelist.conf");
TQString progPath = locateLocal("data", "kooldock");
TQString menuPath = progPath + TQString("/menu/");
filepath = TQString(progPath + "/ignorelist.conf");
if(ignoreBox->count()>0)
{
QFile out(filepath);
TQFile out(filepath);
if (out.open(IO_WriteOnly))
{
QTextStream out_s(&out);
TQTextStream out_s(&out);
for(int i=0; i<ignoreBox->count(); i++)
{
out_s << ignoreBox->text(i) << "\n";
@ -285,7 +285,7 @@ void SetupDialogPrg::configApply()
}
else
{
QFile::remove(filepath);
TQFile::remove(filepath);
}
emit apply();
}
@ -299,7 +299,7 @@ void SetupDialogPrg::configCancel()
this->hide();
}
void SetupDialogPrg::closeEvent( QCloseEvent *e )
void SetupDialogPrg::closeEvent( TQCloseEvent *e )
{
e->ignore();
configCancel();
@ -371,14 +371,14 @@ void SetupDialogPrg::chkHidden()
cbStayBelow->setEnabled(!tmp);
}
void SetupDialogPrg::applist_dropped(QDropEvent*e,const QValueList<QIconDragItem>&)
void SetupDialogPrg::applist_dropped(TQDropEvent*e,const TQValueList<TQIconDragItem>&)
{
KIconLoader icon_obj;
QStringList lst;
QString name;
TQStringList lst;
TQString name;
int pos;
QUriDrag::decodeLocalFiles(e, lst);
TQUriDrag::decodeLocalFiles(e, lst);
name=lst[0];
//Lets see if it is a desktop file
@ -421,18 +421,18 @@ void SetupDialogPrg::removeLauncher()
{
if(fileName!=NULL)
{
QString question=i18n("Do you want to remove ") + fileName + QString("?");
TQString question=i18n("Do you want to remove ") + fileName + TQString("?");
int remove = KMessageBox::questionYesNo(0, question, i18n("Remove Launcher"));
if(remove!=KMessageBox::Yes) return;
KSimpleConfig *desktopfile;
QDir homeDir = QDir::home();
TQDir homeDir = TQDir::home();
if (homeDir.exists(progPath))
{
QDir dir(menuPath);
QStringList fileListRemove;
TQDir dir(menuPath);
TQStringList fileListRemove;
fileListRemove = dir.entryList("*.desktop");
for ( QStringList::Iterator it = fileListRemove.begin(); it != fileListRemove.end(); ++it )
for ( TQStringList::Iterator it = fileListRemove.begin(); it != fileListRemove.end(); ++it )
{
if ( ((*it) != ".") && ((*it) != "..") )
{
@ -442,15 +442,15 @@ void SetupDialogPrg::removeLauncher()
{
kdDebug(0) << "Removing " << menuPath + (*it) << endl;
delete(desktopfile);
if(QFile::remove(menuPath+(*it))==TRUE)
if(TQFile::remove(menuPath+(*it))==TRUE)
{
kdDebug(0) << "Item removed!" << endl;
//Lets update the launchers index
QString preffix;
TQString preffix;
fileListRemove.clear();
fileListRemove=dir.entryList("*.desktop");
QStringList fileListRemove2=fileListRemove;
TQStringList fileListRemove2=fileListRemove;
//Not really sure why I couldn't do this within the other for, something like fileListRemove[i].remove(0,2).prepend(preffix), but hell it works
for(unsigned int i=0; i<fileListRemove2.count(); i++)
@ -461,10 +461,10 @@ void SetupDialogPrg::removeLauncher()
//Rename the files so they reflect their new position
for(unsigned int i=0; i<fileListRemove.count(); i++)
{
if(i<10) preffix=QString("0%1").arg(i);
if(i>=10) preffix=QString("%1").arg(i);
if(i<10) preffix=TQString("0%1").arg(i);
if(i>=10) preffix=TQString("%1").arg(i);
dir.rename(fileListRemove[i], QString("%1%2").arg(preffix).arg(fileListRemove2[i]));
dir.rename(fileListRemove[i], TQString("%1%2").arg(preffix).arg(fileListRemove2[i]));
}
//End updating
@ -507,7 +507,7 @@ void SetupDialogPrg::activeWindowChanged(WId id)
{
KWin::WindowInfo winfo;
winfo=KWin::windowInfo(id);
QString ninfo=winfo.visibleName();
TQString ninfo=winfo.visibleName();
if(ninfo!=caption())
{
@ -523,7 +523,7 @@ void SetupDialogPrg::buttonadd_clicked()
appdlg->show();
}
void SetupDialogPrg::showEvent(QShowEvent *)
void SetupDialogPrg::showEvent(TQShowEvent *)
{
//Here we fill the applist
appFill();
@ -534,23 +534,23 @@ void SetupDialogPrg::appFill()
// fill the application list.
KSimpleConfig *desktopfile;
QDir homeDir = QDir::home();
TQDir homeDir = TQDir::home();
KIconLoader icon_obj;
QPixmap pixm;
TQPixmap pixm;
if(homeDir.exists(progPath))
{
QDir dir(menuPath);
TQDir dir(menuPath);
fileList.clear();
fileList = dir.entryList("*.desktop");
for ( QStringList::Iterator it = fileList.begin(); it != fileList.end(); ++it )
for ( TQStringList::Iterator it = fileList.begin(); it != fileList.end(); ++it )
{
if ( ((*it) != ".") && ((*it) != "..") )
{
desktopfile = new KSimpleConfig( menuPath + (*it), TRUE);
desktopfile->setGroup("Desktop Entry");
QPixmap pixm=icon_obj.loadIcon(desktopfile->readEntry("Icon") ,KIcon::Desktop,0,KIcon::DefaultState,0L,false);
TQPixmap pixm=icon_obj.loadIcon(desktopfile->readEntry("Icon") ,KIcon::Desktop,0,KIcon::DefaultState,0L,false);
new KIconViewItem(applist, desktopfile->readEntry("Name"), pixm);
delete(desktopfile);
}
@ -558,7 +558,7 @@ void SetupDialogPrg::appFill()
}
}
void SetupDialogPrg::hideEvent ( QHideEvent * )
void SetupDialogPrg::hideEvent ( TQHideEvent * )
{
// the application list is erased here.
appClear();
@ -579,14 +579,14 @@ void SetupDialogPrg::right()
if (oldPos!=-1 && oldPos < (int)fileList.count()-1) {setnewpos(oldPos+1); oldPos++;iconsChanged();}
}
void SetupDialogPrg::applist_clicked(QIconViewItem *e, const QPoint&)
void SetupDialogPrg::applist_clicked(TQIconViewItem *e, const TQPoint&)
{
if(e!=NULL)
{oldPos=e->index();}
else
{oldPos=-1;}
}
void SetupDialogPrg::applist_contextMenuRequested(QIconViewItem *e,const QPoint&)
void SetupDialogPrg::applist_contextMenuRequested(TQIconViewItem *e,const TQPoint&)
{
if(e!=NULL)
{
@ -600,17 +600,17 @@ void SetupDialogPrg::applist_contextMenuRequested(QIconViewItem *e,const QPoint&
//Load desktop data
KSimpleConfig *desktopfile;
QDir dir(menuPath);
TQDir dir(menuPath);
fileList.clear();
fileList = dir.entryList("*.desktop");
int i=0;
for ( QStringList::Iterator it = fileList.begin(); it != fileList.end(); ++it )
for ( TQStringList::Iterator it = fileList.begin(); it != fileList.end(); ++it )
{
if ( ((*it) != ".") && ((*it) != "..") )
{
desktopfile = new KSimpleConfig( menuPath + (*it), TRUE);
desktopfile->setGroup("Desktop Entry");
int menustate=setpos->insertItem(QString("%1").arg(desktopfile->readEntry("Name")),i);
int menustate=setpos->insertItem(TQString("%1").arg(desktopfile->readEntry("Name")),i);
if(i==oldPos) {setpos->setItemEnabled(menustate, false);filepath=menuPath + (*it);}
delete(desktopfile);
i++;
@ -622,7 +622,7 @@ void SetupDialogPrg::applist_contextMenuRequested(QIconViewItem *e,const QPoint&
popup->insertItem(i18n("Swap with"), setpos);
popup->insertItem(i18n("&Edit item"), this, SLOT(editItem()));
popup->insertItem(i18n("Remove"), this, SLOT(removeLauncher()));
popup->exec(QCursor::pos());
popup->exec(TQCursor::pos());
if(popup) delete(popup);
if(setpos) delete(setpos);
}
@ -639,15 +639,15 @@ void SetupDialogPrg::editItem()
void SetupDialogPrg::setnewpos(int newpos)
{
kdDebug(0) << "New pos " << QString("0%1").arg(newpos) << "requested for: " << fileName<< endl;
kdDebug(0) << "New pos " << TQString("0%1").arg(newpos) << "requested for: " << fileName<< endl;
if(newpos==oldPos) return; //Nothing to be done
computeNewPos(newpos);
}
void SetupDialogPrg::computeNewPos(int pos)
{
QString preffix, preffix2;
QDir dir(menuPath);
TQString preffix, preffix2;
TQDir dir(menuPath);
fileList.clear();
fileList = dir.entryList("*.desktop");
@ -659,18 +659,18 @@ void SetupDialogPrg::computeNewPos(int pos)
}
//Preffix for old position
if(oldPos<10) preffix=QString("0%1").arg(oldPos);
if(oldPos>=10) preffix=QString("%1").arg(oldPos);
if(oldPos<10) preffix=TQString("0%1").arg(oldPos);
if(oldPos>=10) preffix=TQString("%1").arg(oldPos);
//Preffix for new position
if(pos<10) preffix2=QString("0%1").arg(pos);
if(pos>=10) preffix2=QString("%1").arg(pos);
if(pos<10) preffix2=TQString("0%1").arg(pos);
if(pos>=10) preffix2=TQString("%1").arg(pos);
kdDebug(0) << "Old Position: " << oldPos << endl;
kdDebug(0) << "New Position: " << pos << endl;
dir.rename(QString("%1%2").arg(preffix).arg(fileList[oldPos]), QString("%1%2").arg(preffix2).arg(fileList[oldPos]));
dir.rename(QString("%1%2").arg(preffix2).arg(fileList[pos]), QString("%1%2").arg(preffix).arg(fileList[pos]));
dir.rename(TQString("%1%2").arg(preffix).arg(fileList[oldPos]), TQString("%1%2").arg(preffix2).arg(fileList[oldPos]));
dir.rename(TQString("%1%2").arg(preffix2).arg(fileList[pos]), TQString("%1%2").arg(preffix).arg(fileList[pos]));
appClear();
appFill();

@ -16,16 +16,16 @@
#include "apppropprg.h"
// QT includes
#include <qcolor.h>
#include <qstring.h>
#include <qcheckbox.h>
#include <qlineedit.h>
#include <qspinbox.h>
#include <qfont.h>
#include <qptrlist.h>
#include <qtabwidget.h>
#include <qpushbutton.h>
#include <qradiobutton.h>
#include <ntqcolor.h>
#include <ntqstring.h>
#include <ntqcheckbox.h>
#include <ntqlineedit.h>
#include <ntqspinbox.h>
#include <ntqfont.h>
#include <ntqptrlist.h>
#include <ntqtabwidget.h>
#include <ntqpushbutton.h>
#include <ntqradiobutton.h>
// KDE includes
#include <kfontcombo.h>
@ -48,20 +48,20 @@ class SetupDialogPrg : public SetupDialog
{
Q_OBJECT
public:
SetupDialogPrg(QWidget *parent = 0, const char *name = 0);
SetupDialogPrg(TQWidget *parent = 0, const char *name = 0);
~SetupDialogPrg();
appProp *appdlg;
QString progPath;
QString menuPath;
TQString progPath;
TQString menuPath;
KWinModule *gwm;
KLineEdit *in;
QPushButton *up;
QPushButton *down;
TQPushButton *up;
TQPushButton *down;
int grabbing;
int oldPos;
QString fileName;
QStringList fileList;
QString filepath;
TQString fileName;
TQStringList fileList;
TQString filepath;
public slots:
void editItem();
@ -74,15 +74,15 @@ Q_OBJECT
void chkSolidSlot();
void chkFont();
void chkTask();
void applist_dropped(QDropEvent*,const QValueList<QIconDragItem>&);
void applist_dropped(TQDropEvent*,const TQValueList<TQIconDragItem>&);
void buttonadd_clicked();
void applist_clicked(QIconViewItem *, const QPoint&);
void applist_clicked(TQIconViewItem *, const TQPoint&);
void appRestart();
void appFill();
void appClear();
void grabWin_clicked();
void activeWindowChanged(WId id);
void applist_contextMenuRequested(QIconViewItem*,const QPoint&);
void applist_contextMenuRequested(TQIconViewItem*,const TQPoint&);
void removeLauncher();
void setnewpos(int);
void xrma_clicked();
@ -95,8 +95,8 @@ Q_OBJECT
void computeNewPos(int);
protected:
void closeEvent( QCloseEvent* );
void showEvent ( QShowEvent * );
void hideEvent ( QHideEvent * );
void closeEvent( TQCloseEvent* );
void showEvent ( TQShowEvent * );
void hideEvent ( TQHideEvent * );
};
#endif

@ -1,12 +1,12 @@
#include "xosd.h"
#include <qpainter.h>
#include <qbitmap.h>
#include <qstring.h>
#include <qfont.h>
#include <qfontmetrics.h>
#include <ntqpainter.h>
#include <ntqbitmap.h>
#include <ntqstring.h>
#include <ntqfont.h>
#include <ntqfontmetrics.h>
#include <qwidget.h>
#include <ntqwidget.h>
#include <klocale.h>
#include <netwm.h>
#include <netwm_def.h>
@ -15,9 +15,9 @@
#include <kdebug.h>
#include <stdlib.h>
xosd::xosd(QWidget *parent, const char *name) : QWidget(parent, name, WStyle_Customize | WRepaintNoErase | WStyle_NoBorder | WDestructiveClose | WResizeNoErase | WMouseNoMask | WStyle_StaysOnTop | WX11BypassWM)
xosd::xosd(TQWidget *parent, const char *name) : TQWidget(parent, name, WStyle_Customize | WRepaintNoErase | WStyle_NoBorder | WDestructiveClose | WResizeNoErase | WMouseNoMask | WStyle_StaysOnTop | WX11BypassWM)
{
info = new NETWinInfo( qt_xdisplay(), winId(), qt_xrootwin(), NET::WMState);
info = new NETWinInfo( tqt_xdisplay(), winId(), tqt_xrootwin(), NET::WMState);
info->setDesktop( NETWinInfo::OnAllDesktops );
hide();
KWin::setState(winId(), NET::SkipTaskbar | NET::SkipPager);
@ -28,12 +28,12 @@ xosd::~xosd()
{
}
void xosd::setColor(const QString& color)
void xosd::setColor(const TQString& color)
{
fontColor=color;
}
void xosd::setShadowColor(const QString& color)
void xosd::setShadowColor(const TQString& color)
{
shadowColor=color;
}
@ -46,12 +46,12 @@ void xosd::setOrientation(int orientation, int w, int mh)
if (fCleaner==1)
{
//font is set, so program can get its height to prepare background buffer
QFontMetrics *metrics = new QFontMetrics(f);
TQFontMetrics *metrics = new TQFontMetrics(f);
h = metrics->height();
bgBuffer = QPixmap(dw, h);
maskBuffer = QPixmap(dw, h, true);
bgBuffer = QPixmap::grabWindow(qt_xrootwin(), 0, 0, dw, h);
bgBuffer = TQPixmap(dw, h);
maskBuffer = TQPixmap(dw, h, true);
bgBuffer = TQPixmap::grabWindow(tqt_xrootwin(), 0, 0, dw, h);
lastX=0;
lastY=0;
}
@ -69,15 +69,15 @@ void xosd::setShadowOffset(int off)
shadowOffset=off;
}
void xosd::setText(const QString& t)
void xosd::setText(const TQString& t)
{
//setMask(QRegion(0,0,0,0));
//setMask(TQRegion(0,0,0,0));
// NOTICE: it appears that with WX11BypassWM, resize() doesn't flick the widget anymore :)
// so, setMask() is no more needed.
// -- Matias
resize(0,0);
text = t;
QFontMetrics *metrics = new QFontMetrics(f);
TQFontMetrics *metrics = new TQFontMetrics(f);
w = metrics->width(text);
w = w + shadowOffset + 5; // 5 pixels more
h = metrics->height();
@ -85,7 +85,7 @@ void xosd::setText(const QString& t)
update();
}
void xosd::setFont(const QString& font)
void xosd::setFont(const TQString& font)
{
f.setFamily(font);
}
@ -108,26 +108,26 @@ void xosd::setSize(int size)
/*int xosd::w()
{
QFontMetrics *metrics = new QFontMetrics(f);
TQFontMetrics *metrics = new TQFontMetrics(f);
return (metrics->width(text) + shadowOffset + 5);
}
int xosd::h()
{
QFontMetrics *metrics = new QFontMetrics(f);
TQFontMetrics *metrics = new TQFontMetrics(f);
return metrics->height();
}*/
void xosd::paintEvent(QPaintEvent *)
void xosd::paintEvent(TQPaintEvent *)
{
int i, j;
resize(w,h);
QPixmap pm(size());
QBitmap bm(size());
QPainter p;
TQPixmap pm(size());
TQBitmap bm(size());
TQPainter p;
//Drawing text
p.begin(&pm, this);
@ -139,15 +139,15 @@ void xosd::paintEvent(QPaintEvent *)
else
{
//One colour background - work faster
p.fillRect (rect(), QColor(shadowColor));
p.fillRect (rect(), TQColor(shadowColor));
}
p.setPen( QColor(shadowColor) );
p.setPen( TQColor(shadowColor) );
p.setFont(f);
p.drawText(shadowOffset, yOffset + shadowOffset, text, AlignCenter); // draw shadow text
// now, draw normal text
p.setPen( QColor(fontColor) );
p.setPen( TQColor(fontColor) );
p.drawText(1, yOffset, text, AlignCenter); // draw front text
@ -156,8 +156,8 @@ void xosd::paintEvent(QPaintEvent *)
//Drawing mask
p.begin(&bm, this);
// now we must draw the text with black color for making the mask
p.setPen( Qt::white );
p.fillRect (rect(), Qt::black);
p.setPen( TQt::white );
p.fillRect (rect(), TQt::black);
p.setFont(f);
for (i=-fCleaner;i<=fCleaner;i++)
{
@ -183,33 +183,33 @@ void xosd::move2(int x, int y)
{
if (fCleaner==1)
{
QPixmap tmpBuffer;
TQPixmap tmpBuffer;
//window is not hidden
if (y!=rdh)
{
tmpBuffer = QPixmap::grabWindow(qt_xrootwin(), 0, y, dw, h);
tmpBuffer = TQPixmap::grabWindow(tqt_xrootwin(), 0, y, dw, h);
if (lastY!=rdh)
{
//fill background covered with the text with cached version
if (fOrientation==0 ) //horizontal
{
bitBlt(&tmpBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, Qt::AndROP);//copying part, which hides only the text
bitBlt(&bgBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, Qt::NotAndROP);//so the background won't be covered by
bitBlt(&tmpBuffer, lastX, 0, &bgBuffer, lastX, 0, w, h, Qt::OrROP);//currently visible text.
bitBlt(&tmpBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, TQt::AndROP);//copying part, which hides only the text
bitBlt(&bgBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, TQt::NotAndROP);//so the background won't be covered by
bitBlt(&tmpBuffer, lastX, 0, &bgBuffer, lastX, 0, w, h, TQt::OrROP);//currently visible text.
}
if (fOrientation==1) //vertical
{
if (y<lastY && (y+h)>lastY)
{
bitBlt(&tmpBuffer, lastX, lastY-y, &maskBuffer, 0, 0, w, h, Qt::AndROP);
bitBlt(&bgBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, Qt::NotAndROP);
bitBlt(&tmpBuffer, lastX, lastY-y, &bgBuffer, lastX, 0, w, h, Qt::OrROP);
bitBlt(&tmpBuffer, lastX, lastY-y, &maskBuffer, 0, 0, w, h, TQt::AndROP);
bitBlt(&bgBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, TQt::NotAndROP);
bitBlt(&tmpBuffer, lastX, lastY-y, &bgBuffer, lastX, 0, w, h, TQt::OrROP);
}
if (y>lastY && (y-lastY)<h)
{
bitBlt(&tmpBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, Qt::AndROP);
bitBlt(&bgBuffer, lastX, y-lastY, &maskBuffer, 0, 0, w, h, Qt::NotAndROP);
bitBlt(&tmpBuffer, lastX, 0, &bgBuffer, lastX, y-lastY, w, h, Qt::OrROP);
bitBlt(&tmpBuffer, lastX, 0, &maskBuffer, 0, 0, w, h, TQt::AndROP);
bitBlt(&bgBuffer, lastX, y-lastY, &maskBuffer, 0, 0, w, h, TQt::NotAndROP);
bitBlt(&tmpBuffer, lastX, 0, &bgBuffer, lastX, y-lastY, w, h, TQt::OrROP);
}
}
}

@ -5,29 +5,29 @@
#include <config.h>
#endif
#include <qstring.h>
#include <qwidget.h>
#include <qfont.h>
#include <qpixmap.h>
#include <qbitmap.h>
#include <ntqstring.h>
#include <ntqwidget.h>
#include <ntqfont.h>
#include <ntqpixmap.h>
#include <ntqbitmap.h>
#include <netwm.h>
#include <kwin.h>
class xosd : public QWidget
class xosd : public TQWidget
{
Q_OBJECT
public:
xosd(QWidget* parent=0, const char *name=0);
xosd(TQWidget* parent=0, const char *name=0);
virtual ~xosd();
void setText(const QString& t);
void setFont(const QString& font);
void setText(const TQString& t);
void setFont(const TQString& font);
void setItalic();
void setBold();
void setSize(int size);
void setColor(const QString& color);
void setShadowColor(const QString& color);
void setColor(const TQString& color);
void setShadowColor(const TQString& color);
void setShadowOffset(int off);
void move2(int x, int y);
void setOrientation(int orientation, int w, int mh);
@ -36,23 +36,23 @@ Q_OBJECT
int w, h;
int fontSize;
int fontStyle;
QString fontFamily;
TQString fontFamily;
private:
NETWinInfo *info;
QString text;
QFont f;
QString fontColor;
QString shadowColor;
TQString text;
TQFont f;
TQString fontColor;
TQString shadowColor;
int shadowOffset;
int fOrientation;
QPixmap bgBuffer;
TQPixmap bgBuffer;
int dw, rdh;
int lastX, lastY;
int fCleaner;
QPixmap maskBuffer;
TQPixmap maskBuffer;
protected:
void paintEvent(QPaintEvent *);
void paintEvent(TQPaintEvent *);
};
#endif // XOSD_H_

Loading…
Cancel
Save