Restore console default statements exec.
authorDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 11 Aug 2014 17:27:37 +0000 (19:27 +0200)
committerDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 11 Aug 2014 17:27:37 +0000 (19:27 +0200)
python/src/com/jetbrains/python/console/PydevConsoleRunner.java

index 3010786a491c0c9c05e8bf17970eb5104f9058ac..b3ebacd83ae335eaa37b166deee60f73cc7ea7c0 100644 (file)
@@ -148,11 +148,12 @@ public class PydevConsoleRunner extends AbstractConsoleRunnerWithHistory<PythonC
   public PydevConsoleRunner(@NotNull final Project project,
                                @NotNull Sdk sdk, @NotNull final PyConsoleType consoleType,
                                @Nullable final String workingDir,
-                               Map<String, String> environmentVariables, String[] statementsToExecute) {
+                               Map<String, String> environmentVariables, String ... statementsToExecute) {
     super(project, consoleType.getTitle(), workingDir);
     mySdk = sdk;
     myConsoleType = consoleType;
     myEnvironmentVariables = environmentVariables;
+    myStatementsToExecute = statementsToExecute;
   }
 
   public static PathMappingSettings getMappings(Project project, Sdk sdk) {
@@ -160,6 +161,7 @@ public class PydevConsoleRunner extends AbstractConsoleRunnerWithHistory<PythonC
     if (PySdkUtil.isRemote(sdk)) {
       PythonRemoteInterpreterManager instance = PythonRemoteInterpreterManager.getInstance();
       if (instance != null) {
+        //noinspection ConstantConditions
         mappingSettings =
           instance.setupMappings(project, (PyRemoteSdkAdditionalDataBase)sdk.getSdkAdditionalData(), null);
       }