fix the border disable logic
This commit is contained in:
parent
e571a8ea6e
commit
8c8d4bfb09
|
@ -171,7 +171,9 @@ void DialogPrivate::checkBorders(bool updateMaskIfNeeded)
|
||||||
qreal bottomHeight(0);
|
qreal bottomHeight(0);
|
||||||
|
|
||||||
//decide about disabling the border attached to the panel
|
//decide about disabling the border attached to the panel
|
||||||
if (applet && !(q->windowFlags() & Qt::ToolTip)) {
|
//don't cut borders on tooltips
|
||||||
|
//Qt::ToolTip is 0xc & Qt::Window, so Qt::Window has to be considered
|
||||||
|
if (applet && (q->windowFlags() & Qt::ToolTip) != Qt::ToolTip) {
|
||||||
background->getMargins(leftWidth, topHeight, rightWidth, bottomHeight);
|
background->getMargins(leftWidth, topHeight, rightWidth, bottomHeight);
|
||||||
|
|
||||||
switch (applet->location()) {
|
switch (applet->location()) {
|
||||||
|
@ -223,7 +225,7 @@ void DialogPrivate::checkBorders(bool updateMaskIfNeeded)
|
||||||
}
|
}
|
||||||
|
|
||||||
//decide if to disable the other borders
|
//decide if to disable the other borders
|
||||||
if (q->isVisible() && !(q->windowFlags() & Qt::ToolTip)) {
|
if (q->isVisible() && (q->windowFlags() & Qt::ToolTip) != Qt::ToolTip) {
|
||||||
if (dialogGeom.left() <= avail.left()) {
|
if (dialogGeom.left() <= avail.left()) {
|
||||||
borders &= ~FrameSvg::LeftBorder;
|
borders &= ~FrameSvg::LeftBorder;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user