Commit 60342d44 authored by Martin Flöser's avatar Martin Flöser

Move adjustedSize from Client to AbstractClient

parent 7c49b1ca
......@@ -413,6 +413,9 @@ public:
*/
virtual QSize sizeForClientSize(const QSize &wsize, Sizemode mode = SizemodeAny, bool noframe = false) const;
QSize adjustedSize(const QSize&, Sizemode mode = SizemodeAny) const;
QSize adjustedSize() const;
virtual bool hasStrut() const;
void setModal(bool modal);
......
......@@ -209,9 +209,6 @@ public:
void releaseWindow(bool on_shutdown = false);
void destroyClient();
QSize adjustedSize(const QSize&, Sizemode mode = SizemodeAny) const;
QSize adjustedSize() const;
virtual int desktop() const;
void sendToScreen(int screen) override;
......
......@@ -1271,7 +1271,7 @@ void AbstractClient::checkOffscreenPosition(QRect* geom, const QRect& screenArea
/*!
Adjust the frame size \a frame according to he window's size hints.
*/
QSize Client::adjustedSize(const QSize& frame, Sizemode mode) const
QSize AbstractClient::adjustedSize(const QSize& frame, Sizemode mode) const
{
// first, get the window size for the given frame size s
QSize wsize(frame.width() - (borderLeft() + borderRight()),
......@@ -1284,7 +1284,7 @@ QSize Client::adjustedSize(const QSize& frame, Sizemode mode) const
// this helper returns proper size even if the window is shaded
// see also the comment in Client::setGeometry()
QSize Client::adjustedSize() const
QSize AbstractClient::adjustedSize() const
{
return sizeForClientSize(clientSize());
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment