Remove outdated showWindowMenu(At) functions
Instead of wrapping for exactly one case let's just use the proper function calls and get rid of all those methods marked as "remove KDE4" and "backwards compatibility". REVIEW: 110292
This commit is contained in:
parent
8bd3b28335
commit
c4c3eb90fb
3 changed files with 6 additions and 28 deletions
|
@ -154,7 +154,10 @@ void DBusInterface::doNotManage(const QString &name)
|
|||
|
||||
void DBusInterface::showWindowMenuAt(qlonglong winId, int x, int y)
|
||||
{
|
||||
Workspace::self()->showWindowMenuAt(winId, x, y);
|
||||
Q_UNUSED(winId)
|
||||
Q_UNUSED(x)
|
||||
Q_UNUSED(y)
|
||||
Workspace::self()->slotWindowOperations();
|
||||
}
|
||||
|
||||
// wrap returning methods with no arguments to COMPOSITOR
|
||||
|
|
|
@ -1205,7 +1205,7 @@ bool Client::performMouseCommand(Options::MouseCommand command, const QPoint &gl
|
|||
case Options::MouseOperationsMenu:
|
||||
if (isActive() && options->isClickRaise())
|
||||
autoRaise();
|
||||
workspace()->showWindowMenu(globalPos, this);
|
||||
workspace()->showWindowMenu(QRect(globalPos, globalPos), this);
|
||||
break;
|
||||
case Options::MouseToggleRaiseAndLower:
|
||||
workspace()->raiseOrLowerClient(this);
|
||||
|
@ -1357,12 +1357,6 @@ bool Client::performMouseCommand(Options::MouseCommand command, const QPoint &gl
|
|||
return replay;
|
||||
}
|
||||
|
||||
// KDE4 remove me
|
||||
void Workspace::showWindowMenuAt(unsigned long, int, int)
|
||||
{
|
||||
slotWindowOperations();
|
||||
}
|
||||
|
||||
void Workspace::slotActivateAttentionWindow()
|
||||
{
|
||||
if (attention_chain.count() > 0)
|
||||
|
@ -1793,7 +1787,7 @@ void Workspace::slotWindowOperations()
|
|||
if (!active_client)
|
||||
return;
|
||||
QPoint pos = active_client->pos() + active_client->clientPos();
|
||||
showWindowMenu(pos.x(), pos.y(), active_client);
|
||||
showWindowMenu(QRect(pos, pos), active_client);
|
||||
}
|
||||
|
||||
void Workspace::showWindowMenu(const QRect &pos, Client* cl)
|
||||
|
|
19
workspace.h
19
workspace.h
|
@ -213,20 +213,11 @@ public:
|
|||
void windowToNextDesktop(Client* c);
|
||||
void sendClientToScreen(Client* c, int screen);
|
||||
|
||||
// KDE4 remove me - And it's also in the DCOP interface :(
|
||||
void showWindowMenuAt(unsigned long id, int x, int y);
|
||||
|
||||
|
||||
/**
|
||||
* Shows the menu operations menu for the client and makes it active if
|
||||
* it's not already.
|
||||
*/
|
||||
void showWindowMenu(const QRect& pos, Client* cl);
|
||||
/**
|
||||
* Backwards compatibility.
|
||||
*/
|
||||
void showWindowMenu(int x, int y, Client* cl);
|
||||
void showWindowMenu(QPoint pos, Client* cl);
|
||||
const UserActionsMenu *userActionsMenu() const {
|
||||
return m_userActionsMenu;
|
||||
}
|
||||
|
@ -627,16 +618,6 @@ inline const ToplevelList& Workspace::stackingOrder() const
|
|||
return stacking_order;
|
||||
}
|
||||
|
||||
inline void Workspace::showWindowMenu(QPoint pos, Client* cl)
|
||||
{
|
||||
showWindowMenu(QRect(pos, pos), cl);
|
||||
}
|
||||
|
||||
inline void Workspace::showWindowMenu(int x, int y, Client* cl)
|
||||
{
|
||||
showWindowMenu(QRect(QPoint(x, y), QPoint(x, y)), cl);
|
||||
}
|
||||
|
||||
inline void Workspace::setWasUserInteraction()
|
||||
{
|
||||
was_user_interaction = true;
|
||||
|
|
Loading…
Reference in a new issue