From 69db6f89724615cbc19a5db6d7215db37f63e8f1 Mon Sep 17 00:00:00 2001 From: Konstantin Bulenkov Date: Mon, 28 Aug 2017 13:23:42 +0300 Subject: [PATCH] disable warnings in PassThrough mode --- .../com/intellij/ide/util/treeView/AbstractTreeUi.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java index 40bf789ae495..6eab36bc1b7f 100644 --- a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java +++ b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java @@ -1,5 +1,5 @@ /* - * Copyright 2000-2016 JetBrains s.r.o. + * Copyright 2000-2017 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -5097,9 +5097,11 @@ public class AbstractTreeUi { }); } - private static void warnMap(String prefix, Map map) { + private void warnMap(String prefix, Map map) { if (!LOG.isDebugEnabled()) return; - if (!SwingUtilities.isEventDispatchThread()) LOG.warn(prefix + "modified on wrong thread"); + if (!SwingUtilities.isEventDispatchThread() && !myPassThroughMode) { + LOG.warn(prefix + "modified on wrong thread"); + } long count = map.keySet().stream().filter(AbstractTreeUi::isNodeNull).count(); if (count > 0) LOG.warn(prefix + "null keys: " + count + " / " + map.size()); }