summaryrefslogtreecommitdiffstats
path: root/kicker/applets/systemtray/systemtrayapplet.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kicker/applets/systemtray/systemtrayapplet.cpp')
-rw-r--r--kicker/applets/systemtray/systemtrayapplet.cpp96
1 files changed, 48 insertions, 48 deletions
diff --git a/kicker/applets/systemtray/systemtrayapplet.cpp b/kicker/applets/systemtray/systemtrayapplet.cpp
index 97b71d1b2..50781f9cd 100644
--- a/kicker/applets/systemtray/systemtrayapplet.cpp
+++ b/kicker/applets/systemtray/systemtrayapplet.cpp
@@ -63,7 +63,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
extern "C"
{
- KDE_EXPORT KPanelApplet* init(TQWidget *parent, const TQString& configFile)
+ TDE_EXPORT KPanelApplet* init(TQWidget *parent, const TQString& configFile)
{
TDEGlobal::locale()->insertCatalogue("ksystemtrayapplet");
return new SystemTrayApplet(configFile, KPanelApplet::Normal,
@@ -99,19 +99,19 @@ SystemTrayApplet::SystemTrayApplet(const TQString& configFile, Type type, int ac
m_clockApplet = new ClockApplet(configFile, KPanelApplet::Normal, KPanelApplet::Preferences, this, "clockapplet");
updateClockGeometry();
- connect(m_clockApplet, TQT_SIGNAL(clockReconfigured()), this, TQT_SLOT(updateClockGeometry()));
- connect(m_clockApplet, TQT_SIGNAL(updateLayout()), this, TQT_SLOT(updateClockGeometry()));
+ connect(m_clockApplet, TQ_SIGNAL(clockReconfigured()), this, TQ_SLOT(updateClockGeometry()));
+ connect(m_clockApplet, TQ_SIGNAL(updateLayout()), this, TQ_SLOT(updateClockGeometry()));
setBackgroundOrigin(AncestorOrigin);
- twin_module = new KWinModule(TQT_TQOBJECT(this));
+ twin_module = new KWinModule(this);
// kApplication notifies us of settings changes. added to support
// disabling of frame effect on mouse hover
kapp->dcopClient()->setNotifications(true);
connectDCOPSignal("kicker", "kicker", "configurationChanged()", "loadSettings()", false);
- TQTimer::singleShot(0, this, TQT_SLOT(initialize()));
+ TQTimer::singleShot(0, this, TQ_SLOT(initialize()));
}
void SystemTrayApplet::updateClockGeometry()
@@ -119,7 +119,7 @@ void SystemTrayApplet::updateClockGeometry()
if (m_clockApplet)
{
m_clockApplet->setPosition(position());
- if (orientation() == Qt::Horizontal)
+ if (orientation() == TQt::Horizontal)
{
m_clockApplet->setFixedSize(m_clockApplet->widthForHeight(height()),height());
}
@@ -151,10 +151,10 @@ void SystemTrayApplet::initialize()
}
// the KWinModule notifies us when tray windows are added or removed
- connect( twin_module, TQT_SIGNAL( systemTrayWindowAdded(WId) ),
- this, TQT_SLOT( systemTrayWindowAdded(WId) ) );
- connect( twin_module, TQT_SIGNAL( systemTrayWindowRemoved(WId) ),
- this, TQT_SLOT( updateTrayWindows() ) );
+ connect( twin_module, TQ_SIGNAL( systemTrayWindowAdded(WId) ),
+ this, TQ_SLOT( systemTrayWindowAdded(WId) ) );
+ connect( twin_module, TQ_SIGNAL( systemTrayWindowRemoved(WId) ),
+ this, TQ_SLOT( updateTrayWindows() ) );
TQCString screenstr;
screenstr.setNum(tqt_xscreen());
@@ -249,11 +249,11 @@ void SystemTrayApplet::preferences()
KDialogBase::Ok | KDialogBase::Apply | KDialogBase::Cancel,
KDialogBase::Ok, true);
m_settingsDialog->resize(450, 400);
- connect(m_settingsDialog, TQT_SIGNAL(applyClicked()), this, TQT_SLOT(applySettings()));
- connect(m_settingsDialog, TQT_SIGNAL(okClicked()), this, TQT_SLOT(applySettings()));
- connect(m_settingsDialog, TQT_SIGNAL(finished()), this, TQT_SLOT(settingsDialogFinished()));
+ connect(m_settingsDialog, TQ_SIGNAL(applyClicked()), this, TQ_SLOT(applySettings()));
+ connect(m_settingsDialog, TQ_SIGNAL(okClicked()), this, TQ_SLOT(applySettings()));
+ connect(m_settingsDialog, TQ_SIGNAL(finished()), this, TQ_SLOT(settingsDialogFinished()));
- TQGrid *settingsGrid = m_settingsDialog->makeGridMainWidget( 2, Qt::Vertical);
+ TQGrid *settingsGrid = m_settingsDialog->makeGridMainWidget( 2, TQt::Vertical);
m_showClockSettingCB = new TQCheckBox(i18n("Show Clock in Tray"), settingsGrid);
m_showClockSettingCB->setChecked(m_showClockInTray);
@@ -432,11 +432,11 @@ void SystemTrayApplet::showExpandButton(bool show)
{
if (!m_expandButton)
{
- m_expandButton = new SimpleArrowButton(this, Qt::UpArrow, 0, KickerSettings::showDeepButtons());
+ m_expandButton = new SimpleArrowButton(this, TQt::UpArrow, 0, KickerSettings::showDeepButtons());
m_expandButton->installEventFilter(this);
refreshExpandButton();
- if (orientation() == Qt::Vertical)
+ if (orientation() == TQt::Vertical)
{
m_expandButton->setFixedSize(width() - 4,
m_expandButton->sizeHint()
@@ -448,12 +448,12 @@ void SystemTrayApplet::showExpandButton(bool show)
.width(),
height() - 4);
}
- connect(m_expandButton, TQT_SIGNAL(clicked()),
- this, TQT_SLOT(toggleExpanded()));
+ connect(m_expandButton, TQ_SIGNAL(clicked()),
+ this, TQ_SLOT(toggleExpanded()));
m_autoRetractTimer = new TQTimer(this, "m_autoRetractTimer");
- connect(m_autoRetractTimer, TQT_SIGNAL(timeout()),
- this, TQT_SLOT(checkAutoRetract()));
+ connect(m_autoRetractTimer, TQ_SIGNAL(timeout()),
+ this, TQ_SLOT(checkAutoRetract()));
}
else
{
@@ -559,7 +559,7 @@ void SystemTrayApplet::embedWindow( WId w, bool kde_tray )
return;
}
- connect(emb, TQT_SIGNAL(embeddedWindowDestroyed()), TQT_SLOT(updateTrayWindows()));
+ connect(emb, TQ_SIGNAL(embeddedWindowDestroyed()), TQ_SLOT(updateTrayWindows()));
emb->setFixedSize(m_iconSize, m_iconSize);
if (shouldHide(w))
@@ -677,12 +677,12 @@ void SystemTrayApplet::refreshExpandButton()
return;
}
- Qt::ArrowType a;
+ TQt::ArrowType a;
- if (orientation() == Qt::Vertical)
- a = m_showHidden ? Qt::DownArrow : Qt::UpArrow;
+ if (orientation() == TQt::Vertical)
+ a = m_showHidden ? TQt::DownArrow : TQt::UpArrow;
else
- a = (m_showHidden ^ kapp->reverseLayout()) ? Qt::RightArrow : Qt::LeftArrow;
+ a = (m_showHidden ^ kapp->reverseLayout()) ? TQt::RightArrow : TQt::LeftArrow;
m_expandButton->setArrowType(a);
}
@@ -833,17 +833,17 @@ int SystemTrayApplet::maxIconHeight() const
bool SystemTrayApplet::eventFilter(TQObject* watched, TQEvent* e)
{
- if (TQT_BASE_OBJECT(watched) == TQT_BASE_OBJECT(m_expandButton))
+ if (watched == m_expandButton)
{
TQPoint p;
if (e->type() == TQEvent::ContextMenu)
{
- p = TQT_TQCONTEXTMENUEVENT(e)->globalPos();
+ p = static_cast<TQContextMenuEvent*>(e)->globalPos();
}
else if (e->type() == TQEvent::MouseButtonPress)
{
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
- if (me->button() == Qt::RightButton)
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
+ if (me->button() == TQt::RightButton)
{
p = me->globalPos();
}
@@ -853,9 +853,9 @@ bool SystemTrayApplet::eventFilter(TQObject* watched, TQEvent* e)
{
TQPopupMenu* contextMenu = new TQPopupMenu(this);
contextMenu->insertItem(SmallIcon("configure"), i18n("Configure System Tray..."),
- this, TQT_SLOT(configure()));
+ this, TQ_SLOT(configure()));
- contextMenu->exec(TQT_TQCONTEXTMENUEVENT(e)->globalPos());
+ contextMenu->exec(static_cast<TQContextMenuEvent*>(e)->globalPos());
delete contextMenu;
return true;
@@ -867,7 +867,7 @@ bool SystemTrayApplet::eventFilter(TQObject* watched, TQEvent* e)
int SystemTrayApplet::widthForHeight(int h) const
{
- if (orientation() == Qt::Vertical)
+ if (orientation() == TQt::Vertical)
{
return width();
}
@@ -886,7 +886,7 @@ int SystemTrayApplet::widthForHeight(int h) const
int SystemTrayApplet::heightForWidth(int w) const
{
- if (orientation() == Qt::Horizontal)
+ if (orientation() == TQt::Horizontal)
{
return height();
}
@@ -913,7 +913,7 @@ void SystemTrayApplet::resizeEvent( TQResizeEvent* )
{
layoutTray();
// we need to give ourselves a chance to adjust our size before calling this
- TQTimer::singleShot(0, this, TQT_SIGNAL(updateLayout()));
+ TQTimer::singleShot(0, this, TQ_SIGNAL(updateLayout()));
}
void SystemTrayApplet::layoutTray()
@@ -937,7 +937,7 @@ void SystemTrayApplet::layoutTray()
if (m_expandButton)
{
- if (orientation() == Qt::Vertical)
+ if (orientation() == TQt::Vertical)
{
m_expandButton->setFixedSize(width() - 4, m_expandButton->sizeHint().height());
}
@@ -961,7 +961,7 @@ void SystemTrayApplet::layoutTray()
// This fix makes the workarounds in the heightForWidth() and widthForHeight() methods unneeded.
//
- if (orientation() == Qt::Vertical)
+ if (orientation() == TQt::Vertical)
{
int iconWidth = maxIconWidth() + ICON_MARGIN; // +2 for the margins that implied by the layout
heightWidth = width() - ICON_MARGIN;
@@ -972,7 +972,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_leftSpacer,
0, 0,
0, nbrOfLines - 1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
col = 1;
if (showExpandButton)
@@ -980,7 +980,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_expandButton,
1, 1,
0, nbrOfLines - 1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
col = 2;
}
@@ -993,7 +993,7 @@ void SystemTrayApplet::layoutTray()
line = i % nbrOfLines;
(*emb)->show();
m_layout->addWidget((*emb), col, line,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if ((line + 1) == nbrOfLines)
{
@@ -1011,7 +1011,7 @@ void SystemTrayApplet::layoutTray()
line = i % nbrOfLines;
(*emb)->show();
m_layout->addWidget((*emb), col, line,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if ((line + 1) == nbrOfLines)
{
@@ -1024,7 +1024,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_rightSpacer,
col, col,
0, nbrOfLines - 1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if (m_clockApplet) {
if (m_showClockInTray)
@@ -1035,7 +1035,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_clockApplet,
col+1, col+1,
0, nbrOfLines - 1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
}
}
else // horizontal
@@ -1048,7 +1048,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_leftSpacer,
0, nbrOfLines - 1,
0, 0,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
col = 1;
if (showExpandButton)
@@ -1056,7 +1056,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_expandButton,
0, nbrOfLines - 1,
1, 1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
col = 2;
}
@@ -1068,7 +1068,7 @@ void SystemTrayApplet::layoutTray()
line = i % nbrOfLines;
(*emb)->show();
m_layout->addWidget((*emb), line, col,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if ((line + 1) == nbrOfLines)
{
@@ -1086,7 +1086,7 @@ void SystemTrayApplet::layoutTray()
line = i % nbrOfLines;
(*emb)->show();
m_layout->addWidget((*emb), line, col,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if ((line + 1) == nbrOfLines)
{
@@ -1099,7 +1099,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_rightSpacer,
0, nbrOfLines - 1,
col, col,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
if (m_clockApplet) {
if (m_showClockInTray)
@@ -1110,7 +1110,7 @@ void SystemTrayApplet::layoutTray()
m_layout->addMultiCellWidget(m_clockApplet,
0, nbrOfLines - 1,
col+1, col+1,
- Qt::AlignHCenter | Qt::AlignVCenter);
+ TQt::AlignHCenter | TQt::AlignVCenter);
}
}