Move implementation of clientPos() to AbstractClient

The Client's variant works for both Client and ShellClient.
This commit is contained in:
Martin Gräßlin 2015-12-08 10:47:53 +01:00
parent 827486ff36
commit 3de3a959c6
4 changed files with 4 additions and 12 deletions

View file

@ -284,6 +284,10 @@ public:
bool wantsTabFocus() const;
QPoint clientPos() const override {
return QPoint(borderLeft(), borderTop());
}
virtual void updateMouseGrab();
virtual QString caption(bool full = true, bool stripped = false) const = 0;
virtual bool isCloseable() const = 0;

View file

@ -145,7 +145,6 @@ public:
QSize minSize() const override;
QSize maxSize() const override;
QSize basicUnit() const;
virtual QPoint clientPos() const; // Inside of geometry()
virtual QSize clientSize() const;
QPoint inputPos() const { return input_offset; } // Inside of geometry()
@ -719,11 +718,6 @@ inline bool Client::isManaged() const
return m_managed;
}
inline QPoint Client::clientPos() const
{
return QPoint(borderLeft(), borderTop());
}
inline QSize Client::clientSize() const
{
return client_size;

View file

@ -195,11 +195,6 @@ QStringList ShellClient::activities() const
return QStringList();
}
QPoint ShellClient::clientPos() const
{
return QPoint(0, 0);
}
QPoint ShellClient::clientContentPos() const
{
return -1 * clientPos();

View file

@ -43,7 +43,6 @@ public:
virtual ~ShellClient();
QStringList activities() const override;
QPoint clientPos() const override;
QPoint clientContentPos() const override;
QSize clientSize() const override;
QRect transparentRect() const override;