From 4292a95ad83660f305136ce912212229823cb2e6 Mon Sep 17 00:00:00 2001 From: "Vladislav.Soroka" Date: Thu, 20 Jun 2019 19:02:10 +0300 Subject: [PATCH] IDEA-CR-48664 cleanup method name GitOrigin-RevId: c3af55e903eb78d9b94957b0a3ca9c0aeabdf4c5 --- .../intellij/build/AbstractViewManager.java | 22 ++++--------------- 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/platform/lang-impl/src/com/intellij/build/AbstractViewManager.java b/platform/lang-impl/src/com/intellij/build/AbstractViewManager.java index 508b95742d80..a5fede147ce1 100644 --- a/platform/lang-impl/src/com/intellij/build/AbstractViewManager.java +++ b/platform/lang-impl/src/com/intellij/build/AbstractViewManager.java @@ -1,18 +1,4 @@ -/* - * 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. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ +// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.build; import com.intellij.build.events.*; @@ -148,7 +134,7 @@ public abstract class AbstractViewManager implements ViewManager, BuildProgressL } protected void onBuildFinish(BuildDescriptor buildDescriptor) { - clearOrphanIds(Collections.singleton(buildDescriptor)); + clearIdsOf(Collections.singleton(buildDescriptor)); BuildInfo buildInfo = (BuildInfo)buildDescriptor; if (buildInfo.result instanceof FailureResult) { boolean activate = buildInfo.isActivateToolWindowWhenFailed(); @@ -184,10 +170,10 @@ public abstract class AbstractViewManager implements ViewManager, BuildProgressL myPinnedViews.remove(buildsView); } - clearOrphanIds(buildsView.getBuildsMap().keySet()); + clearIdsOf(buildsView.getBuildsMap().keySet()); } - private void clearOrphanIds(@NotNull Collection builds) { + private void clearIdsOf(@NotNull Collection builds) { if (idsMap.isEmpty()) return; Set ids = builds.stream().map(BuildDescriptor::getId).collect(Collectors.toSet()); idsMap.values().removeIf(val -> ids.contains(val));