Move checkOffscreenPosition from Client to AbstractClient
parent
53b87dbbd9
commit
78e9a56cd1
|
@ -525,6 +525,9 @@ protected:
|
||||||
}
|
}
|
||||||
QRect electricBorderMaximizeGeometry(QPoint pos, int desktop);
|
QRect electricBorderMaximizeGeometry(QPoint pos, int desktop);
|
||||||
|
|
||||||
|
// geometry handling
|
||||||
|
void checkOffscreenPosition(QRect *geom, const QRect &screenArea);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void handlePaletteChange();
|
void handlePaletteChange();
|
||||||
QSharedPointer<TabBox::TabBoxClientImpl> m_tabBoxClient;
|
QSharedPointer<TabBox::TabBoxClientImpl> m_tabBoxClient;
|
||||||
|
|
2
client.h
2
client.h
|
@ -635,8 +635,6 @@ private:
|
||||||
xcb_timestamp_t readUserCreationTime() const;
|
xcb_timestamp_t readUserCreationTime() const;
|
||||||
void startupIdChanged();
|
void startupIdChanged();
|
||||||
|
|
||||||
void checkOffscreenPosition (QRect* geom, const QRect& screenArea);
|
|
||||||
|
|
||||||
void updateInputWindow();
|
void updateInputWindow();
|
||||||
|
|
||||||
bool tabTo(Client *other, bool behind, bool activate);
|
bool tabTo(Client *other, bool behind, bool activate);
|
||||||
|
|
|
@ -1254,7 +1254,7 @@ void Client::checkWorkspacePosition(QRect oldGeometry, int oldDesktop, QRect old
|
||||||
setGeometry(newGeom);
|
setGeometry(newGeom);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Client::checkOffscreenPosition(QRect* geom, const QRect& screenArea)
|
void AbstractClient::checkOffscreenPosition(QRect* geom, const QRect& screenArea)
|
||||||
{
|
{
|
||||||
if (geom->left() > screenArea.right()) {
|
if (geom->left() > screenArea.right()) {
|
||||||
geom->moveLeft(screenArea.right() - screenArea.width()/4);
|
geom->moveLeft(screenArea.right() - screenArea.width()/4);
|
||||||
|
|
Loading…
Reference in New Issue