Skip to content
GitLab
Menu
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
018177b5
Commit
018177b5
authored
May 05, 2021
by
Vlad Zahorodnii
Browse files
Limit VRR policy in support information only to Wayland session
Adaptive sync is only supported on Wayland.
BUG: 436623
parent
caaabf84
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/screens.cpp
View file @
018177b5
...
...
@@ -279,7 +279,9 @@ RenderLoop::VrrPolicy Screens::vrrPolicy(int screen) const
return
RenderLoop
::
VrrPolicy
::
Never
;
#else
if
(
auto
output
=
findOutput
(
screen
))
{
return
output
->
renderLoop
()
->
vrrPolicy
();
if
(
auto
waylandOutput
=
dynamic_cast
<
AbstractWaylandOutput
*>
(
output
))
{
return
waylandOutput
->
vrrPolicy
();
}
}
return
RenderLoop
::
VrrPolicy
::
Never
;
#endif
...
...
src/workspace.cpp
View file @
018177b5
...
...
@@ -1538,21 +1538,23 @@ QString Workspace::supportInformation() const
.
arg
(
geo
.
height
()));
support
.
append
(
QStringLiteral
(
"Scale: %1
\n
"
).
arg
(
screens
()
->
scale
(
i
)));
support
.
append
(
QStringLiteral
(
"Refresh Rate: %1
\n
"
).
arg
(
screens
()
->
refreshRate
(
i
)));
QString
vrr
=
QStringLiteral
(
"incapable"
);
if
(
screens
()
->
isVrrCapable
(
i
))
{
switch
(
screens
()
->
vrrPolicy
(
i
))
{
case
RenderLoop
::
VrrPolicy
::
Never
:
vrr
=
QStringLiteral
(
"never"
);
break
;
case
RenderLoop
::
VrrPolicy
::
Always
:
vrr
=
QStringLiteral
(
"always"
);
break
;
case
RenderLoop
::
VrrPolicy
::
Automatic
:
vrr
=
QStringLiteral
(
"automatic"
);
break
;
if
(
waylandServer
())
{
QString
vrr
=
QStringLiteral
(
"incapable"
);
if
(
screens
()
->
isVrrCapable
(
i
))
{
switch
(
screens
()
->
vrrPolicy
(
i
))
{
case
RenderLoop
::
VrrPolicy
::
Never
:
vrr
=
QStringLiteral
(
"never"
);
break
;
case
RenderLoop
::
VrrPolicy
::
Always
:
vrr
=
QStringLiteral
(
"always"
);
break
;
case
RenderLoop
::
VrrPolicy
::
Automatic
:
vrr
=
QStringLiteral
(
"automatic"
);
break
;
}
}
support
.
append
(
QStringLiteral
(
"Adaptive Sync: %1
\n
"
).
arg
(
vrr
));
}
support
.
append
(
QStringLiteral
(
"Adaptive Sync: %1
\n
"
).
arg
(
vrr
));
}
support
.
append
(
QStringLiteral
(
"
\n
Compositing
\n
"
));
support
.
append
(
QStringLiteral
(
"===========
\n
"
));
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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