mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[threading] IJPL-177735: Remove write-intent lock in more event dispatchers
GitOrigin-RevId: bdd2c067cfb2e0f78b3bff84f5484f197ee472c0
This commit is contained in:
committed by
intellij-monorepo-bot
parent
b3cdfb87b0
commit
4f4a05514e
+8
-9
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.openapi.keymap.impl;
|
||||
|
||||
import com.intellij.codeWithMe.ClientId;
|
||||
@@ -103,15 +103,14 @@ public final class ModifierKeyDoubleClickHandler {
|
||||
if (dispatchers.isEmpty()) {
|
||||
return false;
|
||||
}
|
||||
return WriteIntentReadAction.<Boolean, RuntimeException>compute(() -> {
|
||||
boolean innerResult = false;
|
||||
for (MyDispatcher dispatcher : doubleClickHandler.myDispatchers.values()) {
|
||||
if (dispatcher.dispatch(keyEvent)) {
|
||||
innerResult = true;
|
||||
}
|
||||
|
||||
boolean innerResult = false;
|
||||
for (MyDispatcher dispatcher : doubleClickHandler.myDispatchers.values()) {
|
||||
if (dispatcher.dispatch(keyEvent)) {
|
||||
innerResult = true;
|
||||
}
|
||||
return innerResult;
|
||||
});
|
||||
}
|
||||
return innerResult;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+6
-2
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.internal.inspector
|
||||
|
||||
import com.intellij.ide.IdeEventQueue
|
||||
@@ -41,7 +41,11 @@ abstract class UiMouseAction(val uiActionId: String) : DumbAwareAction() {
|
||||
}
|
||||
})
|
||||
|
||||
IdeEventQueue.getInstance().addDispatcher(::handleEvent, ApplicationManager.getApplication())
|
||||
IdeEventQueue.getInstance().addDispatcher(object : IdeEventQueue.NonLockedEventDispatcher {
|
||||
override fun dispatch(e: AWTEvent): Boolean {
|
||||
return handleEvent(e)
|
||||
}
|
||||
}, ApplicationManager.getApplication())
|
||||
}
|
||||
|
||||
private fun handleEvent(event: AWTEvent): Boolean {
|
||||
|
||||
Reference in New Issue
Block a user