Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
KWin
Commits
151be458
Commit
151be458
authored
Jan 20, 2022
by
Vlad Zahorodnii
Browse files
Prefer isDecorated() over noBorder() when checking if window is decorated
parent
87f2f900
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/abstract_client.cpp
View file @
151be458
...
...
@@ -603,7 +603,7 @@ void AbstractClient::setShade(ShadeMode mode)
return
;
if
(
mode
==
ShadeHover
&&
isInteractiveMove
())
return
;
// causes geometry breaks and is probably nasty
if
(
isSpecialWindow
()
||
noBorder
())
if
(
isSpecialWindow
()
||
!
isDecorated
())
mode
=
ShadeNone
;
mode
=
rules
()
->
checkShade
(
mode
);
...
...
src/x11client.cpp
View file @
151be458
...
...
@@ -1049,7 +1049,7 @@ void X11Client::updateInputWindow()
QRegion
region
;
if
(
!
noBorder
()
&&
isD
ecorat
ed
())
{
if
(
d
ecorat
ion
())
{
const
QMargins
&
r
=
decoration
()
->
resizeOnlyBorders
();
const
int
left
=
r
.
left
();
const
int
top
=
r
.
top
();
...
...
@@ -1324,7 +1324,7 @@ void X11Client::updateShape()
noborder
=
rules
()
->
checkNoBorder
(
true
);
updateDecoration
(
true
);
}
if
(
noBorder
())
{
if
(
!
isDecorated
())
{
xcb_shape_combine
(
connection
(),
XCB_SHAPE_SO_SET
,
XCB_SHAPE_SK_BOUNDING
,
XCB_SHAPE_SK_BOUNDING
,
frameId
(),
clientPos
().
x
(),
clientPos
().
y
(),
window
());
}
...
...
@@ -1492,7 +1492,7 @@ QRect X11Client::iconGeometry() const
bool
X11Client
::
isShadeable
()
const
{
return
!
isSpecialWindow
()
&&
!
noBorder
()
&&
(
rules
()
->
checkShade
(
ShadeNormal
)
!=
rules
()
->
checkShade
(
ShadeNone
));
return
!
isSpecialWindow
()
&&
isDecorated
()
&&
(
rules
()
->
checkShade
(
ShadeNormal
)
!=
rules
()
->
checkShade
(
ShadeNone
));
}
void
X11Client
::
doSetShade
(
ShadeMode
previousShadeMode
)
...
...
Vlad Zahorodnii
@vladz
mentioned in commit
a850f976
·
Jan 21, 2022
mentioned in commit
a850f976
mentioned in commit a850f97681d2a00efaf24aab7bfe859aafc1bb71
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment