normalize signal/slot

master
Montel Laurent 12 years ago
parent 68ddc5f236
commit dd8cf0b678

@ -49,7 +49,7 @@ DBusInterface::DBusInterface(QObject *parent)
dbus.registerObject("/KWin", this);
if (!dbus.registerService("org.kde.KWin")) {
QDBusServiceWatcher *dog = new QDBusServiceWatcher("org.kde.KWin", dbus, QDBusServiceWatcher::WatchForUnregistration, this);
connect (dog, SIGNAL(serviceUnregistered(const QString&)), SLOT(becomeKWinService(const QString&)));
connect (dog, SIGNAL(serviceUnregistered(QString)), SLOT(becomeKWinService(QString)));
}
connect(Compositor::self(), SIGNAL(compositingToggled(bool)), SIGNAL(compositingToggled(bool)));
dbus.connect(QString(), "/KWin", "org.kde.KWin", "reloadConfig",

@ -227,7 +227,7 @@ EffectsHandlerImpl::EffectsHandlerImpl(Compositor *compositor, Scene *scene)
Workspace *ws = Workspace::self();
VirtualDesktopManager *vds = VirtualDesktopManager::self();
connect(ws, SIGNAL(currentDesktopChanged(int, KWin::Client*)), SLOT(slotDesktopChanged(int, KWin::Client*)));
connect(ws, SIGNAL(currentDesktopChanged(int,KWin::Client*)), SLOT(slotDesktopChanged(int,KWin::Client*)));
connect(ws, SIGNAL(clientAdded(KWin::Client*)), this, SLOT(slotClientAdded(KWin::Client*)));
connect(ws, SIGNAL(unmanagedAdded(KWin::Unmanaged*)), this, SLOT(slotUnmanagedAdded(KWin::Unmanaged*)));
connect(ws, SIGNAL(clientActivated(KWin::Client*)), this, SLOT(slotClientActivated(KWin::Client*)));

@ -49,8 +49,8 @@ MouseClickEffect::MouseClickEffect()
a->setText(i18n("Toggle Effect"));
a->setGlobalShortcut(KShortcut(Qt::META + Qt::Key_Asterisk));
connect(a, SIGNAL(triggered(bool)), this, SLOT(toggleEnabled()));
connect(effects, SIGNAL(mouseChanged(QPoint, QPoint, Qt::MouseButtons, Qt::MouseButtons, Qt::KeyboardModifiers, Qt::KeyboardModifiers)),
this, SLOT(slotMouseChanged(QPoint, QPoint, Qt::MouseButtons, Qt::MouseButtons, Qt::KeyboardModifiers, Qt::KeyboardModifiers)));
connect(effects, SIGNAL(mouseChanged(QPoint,QPoint,Qt::MouseButtons,Qt::MouseButtons,Qt::KeyboardModifiers,Qt::KeyboardModifiers)),
this, SLOT(slotMouseChanged(QPoint,QPoint,Qt::MouseButtons,Qt::MouseButtons,Qt::KeyboardModifiers,Qt::KeyboardModifiers)));
reconfigure(ReconfigureAll);
m_buttons[0] = new MouseButton(i18n("Left"), Qt::LeftButton);

@ -40,7 +40,7 @@ SnapHelperEffect::SnapHelperEffect()
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
connect(effects, SIGNAL(windowStartUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowStartUserMovedResized(KWin::EffectWindow*)));
connect(effects, SIGNAL(windowFinishUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowFinishUserMovedResized(KWin::EffectWindow*)));
connect(effects, SIGNAL(windowGeometryShapeChanged(KWin::EffectWindow*, const QRect&)), this, SLOT(slotWindowResized(KWin::EffectWindow*, const QRect&)));
connect(effects, SIGNAL(windowGeometryShapeChanged(KWin::EffectWindow*,QRect)), this, SLOT(slotWindowResized(KWin::EffectWindow*,QRect)));
}
SnapHelperEffect::~SnapHelperEffect()

@ -63,8 +63,8 @@ TrackMouseEffectConfig::TrackMouseEffectConfig(QWidget* parent, const QVariantLi
a->setText(i18n("Track mouse"));
a->setProperty("isConfigurationAction", true);
a->setGlobalShortcut(KShortcut());
connect(m_ui->shortcut, SIGNAL(keySequenceChanged(const QKeySequence&)),
SLOT(shortcutChanged(const QKeySequence&)));
connect(m_ui->shortcut, SIGNAL(keySequenceChanged(QKeySequence)),
SLOT(shortcutChanged(QKeySequence)));
load();
}

@ -165,7 +165,7 @@ void KWinDecorationModule::init()
m_ui->decorationList->verticalScrollBar()->disconnect(m_ui->decorationList);
connect(m_ui->decorationList->rootObject(), SIGNAL(contentYChanged()), SLOT(updateScrollbarValue()));
connect(m_ui->decorationList->rootObject(), SIGNAL(contentHeightChanged()), SLOT(updateScrollbarRange()));
connect(m_ui->decorationList->verticalScrollBar(), SIGNAL(rangeChanged(int, int )), SLOT(updateScrollbarRange()));
connect(m_ui->decorationList->verticalScrollBar(), SIGNAL(rangeChanged(int,int)), SLOT(updateScrollbarRange()));
connect(m_ui->decorationList->verticalScrollBar(), SIGNAL(valueChanged(int)), SLOT(updateViewPosition(int)));
m_ui->decorationList->installEventFilter(this);

@ -181,12 +181,12 @@ quint64 AnimationEffect::p_animate( EffectWindow *w, Attribute a, uint meta, int
Q_D(AnimationEffect);
if (d->m_animations.isEmpty()) {
connect (effects, SIGNAL(windowGeometryShapeChanged( KWin::EffectWindow*, const QRect&)),
SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
connect (effects, SIGNAL(windowStepUserMovedResized( KWin::EffectWindow*, const QRect&)),
SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
connect (effects, SIGNAL(windowPaddingChanged( KWin::EffectWindow*, const QRect&)),
SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
connect (effects, SIGNAL(windowGeometryShapeChanged(KWin::EffectWindow*,QRect)),
SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
connect (effects, SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)),
SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
connect (effects, SIGNAL(windowPaddingChanged(KWin::EffectWindow*,QRect)),
SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
}
AniMap::iterator it = d->m_animations.find(w);
if (it == d->m_animations.end())
@ -402,12 +402,12 @@ void AnimationEffect::clipWindow(const EffectWindow *w, const AniData &anim, Win
void AnimationEffect::disconnectGeometryChanges()
{
disconnect (effects,SIGNAL(windowGeometryShapeChanged( KWin::EffectWindow*, const QRect&)),
this, SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
disconnect (effects,SIGNAL(windowStepUserMovedResized( KWin::EffectWindow*, const QRect&)),
this, SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
disconnect (effects,SIGNAL(windowPaddingChanged( KWin::EffectWindow*, const QRect&)),
this, SLOT(_expandedGeometryChanged( KWin::EffectWindow*, const QRect&)));
disconnect (effects,SIGNAL(windowGeometryShapeChanged(KWin::EffectWindow*,QRect)),
this, SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
disconnect (effects,SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)),
this, SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
disconnect (effects,SIGNAL(windowPaddingChanged(KWin::EffectWindow*,QRect)),
this, SLOT(_expandedGeometryChanged(KWin::EffectWindow*,QRect)));
}

@ -108,7 +108,7 @@ QStringList WorkspaceWrapper::activityList() const
#endif
}
#define SLOTWRAPPER( name ) \
#define SLOTWRAPPER(name) \
void WorkspaceWrapper::name( ) { \
Workspace::self()->name(); \
}
@ -168,17 +168,17 @@ SLOTWRAPPER(slotWindowToDesktopDown)
#undef SLOTWRAPPER
#define SLOTWRAPPER( name, direction ) \
#define SLOTWRAPPER(name,direction) \
void WorkspaceWrapper::name( ) { \
VirtualDesktopManager::self()->moveTo<direction>(options->isRollOverDesktops()); \
}
SLOTWRAPPER(slotSwitchDesktopNext, DesktopNext)
SLOTWRAPPER(slotSwitchDesktopPrevious, DesktopPrevious)
SLOTWRAPPER(slotSwitchDesktopRight, DesktopRight)
SLOTWRAPPER(slotSwitchDesktopLeft, DesktopLeft)
SLOTWRAPPER(slotSwitchDesktopUp, DesktopAbove)
SLOTWRAPPER(slotSwitchDesktopDown, DesktopBelow)
SLOTWRAPPER(slotSwitchDesktopNext,DesktopNext)
SLOTWRAPPER(slotSwitchDesktopPrevious,DesktopPrevious)
SLOTWRAPPER(slotSwitchDesktopRight,DesktopRight)
SLOTWRAPPER(slotSwitchDesktopLeft,DesktopLeft)
SLOTWRAPPER(slotSwitchDesktopUp,DesktopAbove)
SLOTWRAPPER(slotSwitchDesktopDown,DesktopBelow)
#undef SLOTWRAPPER

@ -112,7 +112,7 @@ void TestVirtualDesktops::count()
// start with a useful desktop count
vds->setCount(s_countInitValue);
QSignalSpy spy(vds, SIGNAL(countChanged(uint, uint)));
QSignalSpy spy(vds, SIGNAL(countChanged(uint,uint)));
QSignalSpy desktopsRemoved(vds, SIGNAL(desktopsRemoved(uint)));
QFETCH(uint, request);
@ -198,7 +198,7 @@ void TestVirtualDesktops::current()
QVERIFY(vds->setCurrent(init));
QCOMPARE(vds->current(), init);
QSignalSpy spy(vds, SIGNAL(currentChanged(uint, uint)));
QSignalSpy spy(vds, SIGNAL(currentChanged(uint,uint)));
QFETCH(uint, request);
QFETCH(uint, result);
@ -240,7 +240,7 @@ void TestVirtualDesktops::currentChangeOnCountChange()
vds->setCount(initCount);
vds->setCurrent(initCurrent);
QSignalSpy spy(vds, SIGNAL(currentChanged(uint, uint)));
QSignalSpy spy(vds, SIGNAL(currentChanged(uint,uint)));
QFETCH(uint, request);
QFETCH(uint, current);
@ -508,7 +508,7 @@ void TestVirtualDesktops::updateLayout_data()
void TestVirtualDesktops::updateLayout()
{
VirtualDesktopManager *vds = VirtualDesktopManager::self();
QSignalSpy spy(vds, SIGNAL(layoutChanged(int, int)));
QSignalSpy spy(vds, SIGNAL(layoutChanged(int,int)));
// call update layout - implicitly through setCount
QFETCH(uint, desktop);
QFETCH(QSize, result);

Loading…
Cancel
Save