Merge pull request #4939 from TheUbuntuGuy/osd

Fix Pretty OSD positioning on Windows
This commit is contained in:
John Maguire 2015-07-06 06:23:42 -04:00
commit bacbd544a4
1 changed files with 8 additions and 2 deletions

View File

@ -317,8 +317,14 @@ void OSDPretty::Reposition() {
int y = popup_pos_.y() < 0 ? geometry.bottom() - height()
: geometry.top() + popup_pos_.y();
move(qBound(0, x, geometry.right() - width()),
qBound(0, y, geometry.bottom() - height()));
#ifndef Q_OS_WIN32
// windows needs negative coordinates for monitors
// to the left or above the primary
x = qBound(0, x, geometry.right() - width());
y = qBound(0, y, geometry.bottom() - height());
#endif
move(x, y);
// Create a mask for the actual area of the OSD
QBitmap mask(size());