mirror of
https://github.com/JetBrains/JetBrainsRuntime.git
synced 2025-12-06 09:29:38 +01:00
JBR-3896 Abysmally slow input and UI performance since upgrade to IU-213.4928.7 from previous 2021.3 EAP version
The slowness was the result of XWM.getInsetsFromExtents() repeated
attempts to acquire frame extents from a property that under Sway is
simply unavailable. Each attempt added at least 20ms to every re-draw.
Prior to (repeatedly) checking for NET_FRAME_EXTENTS property of a
window, check that the property is supported by the window manager.
(cherry picked from commit b40cc1c791)
This commit is contained in:
@@ -1479,8 +1479,12 @@ final class XWM
|
||||
if (window == XConstants.None) {
|
||||
return null;
|
||||
}
|
||||
XNETProtocol net_protocol = getWM().getNETProtocol();
|
||||
if (net_protocol != null && net_protocol.active()) {
|
||||
final XNETProtocol net_protocol = getWM().getNETProtocol();
|
||||
final boolean frameExtentsSupported =
|
||||
net_protocol != null
|
||||
&& net_protocol.active()
|
||||
&& net_protocol.checkProtocol(net_protocol.XA_NET_SUPPORTED, XA_NET_FRAME_EXTENTS);
|
||||
if (frameExtentsSupported) {
|
||||
Insets insets = null;
|
||||
final int MAX_RETRY_COUNT = 3;
|
||||
for (int i = 0; i < MAX_RETRY_COUNT; i++) {
|
||||
|
||||
Reference in New Issue
Block a user