Set screen for tooltip
This commit is contained in:
parent
39176f619e
commit
89be8d23fc
1 changed files with 1 additions and 0 deletions
|
|
@ -117,6 +117,7 @@ void Tooltip::popup(const QPoint &m, const QString &text, const style::Tooltip *
|
|||
|
||||
// adjust tooltip position
|
||||
if (screen) {
|
||||
setScreen(screen);
|
||||
const auto r = screen->availableGeometry();
|
||||
if (r.x() + r.width() - _st->skip < p.x() + s.width() && p.x() + s.width() > m.x()) {
|
||||
p.setX(qMax(r.x() + r.width() - int32(_st->skip) - s.width(), m.x() - s.width()));
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue