Skip to content

Commit

Permalink
Merge pull request #4420 from Flanker32/hanxiao/fixIntelliJ
Browse files Browse the repository at this point in the history
Fix IntelliJ regression issues
  • Loading branch information
Flanker32 authored May 29, 2020
2 parents 0a188d8 + 04db2f1 commit 6a46ec5
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
1 change: 0 additions & 1 deletion PluginsAndFeatures/azure-toolkit-for-intellij/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,6 @@ dependencies {
}
compile 'com.microsoft.azure:azure-tools-common:0.2.0'
compile group: 'com.microsoft.azure.appplatform.v2019_05_01_preview', name: 'azure-mgmt-appplatform', version: '1.0.0-beta-2'
compile 'com.spotify:docker-client:8.16.0'

compile group: 'org.dom4j', name: 'dom4j', version: '2.1.3'
compile group: 'jaxen', name: 'jaxen', version: '1.2.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import static com.microsoft.azuretools.telemetry.TelemetryConstants.DEPLOY_WEBAPP_DOCKERLOCAL;
import static com.microsoft.azuretools.telemetry.TelemetryConstants.WEBAPP;

import com.google.common.collect.ImmutableList;
import com.intellij.execution.process.ProcessEvent;
import com.intellij.execution.process.ProcessListener;
import com.intellij.execution.process.ProcessOutputTypes;
Expand All @@ -43,6 +42,7 @@
import com.spotify.docker.client.DockerClient;
import com.spotify.docker.client.messages.Container;

import com.spotify.docker.client.shaded.com.google.common.collect.ImmutableList;
import org.jetbrains.annotations.NotNull;

import java.io.FileNotFoundException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,11 +271,11 @@ public synchronized void fillWebApps(List<ResourceEx<WebApp>> webAppLists) {
lblCreateWebApp.setVisible(false);
cbxWebApp.setVisible(true);
cbxWebApp.addItem(CREATE_NEW_WEBAPP);
// Need calculated target id first or fill combo box will trigger event to change selectedWebApp
final String configurationWebAppId = webAppConfiguration.getWebAppId();
final String targetId = (StringUtils.isEmpty(configurationWebAppId) && selectedWebApp != null) ?
selectedWebApp.getResource().id() : configurationWebAppId;
sortedWebAppLists.forEach(webAppResourceEx -> cbxWebApp.addItem(webAppResourceEx));
// Find webapp which id equals to selected web app(when cancel creation) or configuration
// Use the first one as fallback
final String targetId = selectedWebApp == null ? webAppConfiguration.getWebAppId() :
selectedWebApp.getResource().id();
final ResourceEx<WebApp> selectWebApp = sortedWebAppLists
.stream()
.filter(webAppResourceEx -> StringUtils.equals(webAppResourceEx.getResource().id(), targetId))
Expand Down

0 comments on commit 6a46ec5

Please sign in to comment.