Merge remote-tracking branch 'origin/new-winpty'
authorDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 20 Jun 2016 18:36:54 +0000 (20:36 +0200)
committerDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 20 Jun 2016 18:36:54 +0000 (20:36 +0200)
19 files changed:
.idea/libraries/pty4j.xml
build/scripts/libLicenses.gant
lib/libpty/readme.txt
lib/libpty/win/x86/libwinpty.dll [deleted file]
lib/libpty/win/x86/winpty-agent.exe
lib/libpty/win/x86/winpty.dll [new file with mode: 0755]
lib/libpty/win/x86_64/libwinpty.dll [deleted file]
lib/libpty/win/x86_64/winpty-agent.exe
lib/libpty/win/x86_64/winpty.dll [new file with mode: 0644]
lib/libpty/win/xp/libwinpty.dll [deleted file]
lib/libpty/win/xp/winpty-agent.exe
lib/libpty/win/xp/winpty.dll [new file with mode: 0755]
lib/pty4j-0.7.jar [moved from lib/pty4j-0.6.jar with 55% similarity]
lib/required_for_dist.txt
lib/src/pty4j-0.7-src.jar [moved from lib/src/pty4j-0.6-src.jar with 58% similarity]
platform/platform-api/src/com/intellij/execution/process/OSProcessHandler.java
plugins/terminal/lib/jediterm-pty-2.2.jar [moved from plugins/terminal/lib/jediterm-pty-2.1.jar with 66% similarity]
plugins/terminal/src/org/jetbrains/plugins/terminal/JBTabbedTerminalWidget.java
plugins/terminal/terminal.iml

index 49401186e946c3c18c15eee3233ef31e7f75a041..6ff8d23d1170a530b118c096577b85829e2ad544 100644 (file)
@@ -1,11 +1,11 @@
 <component name="libraryTable">
   <library name="pty4j">
     <CLASSES>
-      <root url="jar://$PROJECT_DIR$/lib/pty4j-0.6.jar!/" />
+      <root url="jar://$PROJECT_DIR$/lib/pty4j-0.7.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
-      <root url="jar://$PROJECT_DIR$/lib/src/pty4j-0.6-src.jar!/" />
+      <root url="jar://$PROJECT_DIR$/lib/src/pty4j-0.7-src.jar!/" />
     </SOURCES>
   </library>
 </component>
index 00cb4ced5e579325f747f3d9a244e63ef465160a..89a3e152b7fbed1d8f6781cf84cd72d23db5362c 100644 (file)
@@ -227,7 +227,7 @@ libraryLicense(name: "Jaxen", version: "", license: "modified Apache", url: "htt
 libraryLicense(name: "jayatana", libraryName: "jayatana", version: "1.2.4", license: "MIT License", url: "https://code.google.com/p/java-swing-ayatana/", licenseUrl: "http://opensource.org/licenses/mit-license.php")
 libraryLicense(name: "JCIP Annotations", libraryName: "jcip", license: "Creative Commons Attribution License", url: "http://www.jcip.net", licenseUrl: "http://creativecommons.org/licenses/by/2.5")
 libraryLicense(name: "JDOM", version: "1.1 (with patches by JetBrains)", license: "modified Apache", url: "http://www.jdom.org/", licenseUrl: "http://www.jdom.org/docs/faq.html#a0030")
-libraryLicense(name: "JediTerm", libraryName: "jediterm-pty", version: "0.2", license: "LGPL 2", url: "https://github.com/traff/jediterm", licenseUrl: "https://github.com/traff/jediterm/blob/master/COPYING")
+libraryLicense(name: "JediTerm", libraryName: "jediterm-pty", version: "2.2", license: "LGPL 2", url: "https://github.com/JetBrains/jediterm", licenseUrl: "https://github.com/JetBrains/jediterm/blob/master/COPYING")
 libraryLicense(name: "JEuclid", libraryName: "jeuclid-core-3.1.9.jar", version: "3.1.9", license: "Apache 2.0", url: "http://jeuclid.sourceforge.net", licenseUrl:"http://sourceforge.net/p/jeuclid/code/ci/default/tree/LICENSE.txt")
 libraryLicense(name: "JGit", libraryName: "jackson", version: "2.5.1", license: "Apache 2.0", licenseUrl: "http://www.eclipse.org/org/documents/edl-v10.php", url: "https://github.com/FasterXML/jackson")
 libraryLicense(name: "JGit", libraryName: "jgit", version: "4.0", license: "Eclipse Distribution License 1.0", licenseUrl: "http://www.eclipse.org/org/documents/edl-v10.php", url: "https://eclipse.org/jgit/")
@@ -279,7 +279,7 @@ libraryLicense(name: "Plexus Utils", libraryName: "plexus-utils-1.5.5.jar", vers
 libraryLicense(name: "pockets", attachedTo: "python-helpers", version: "0.2.4", license: "BSD", url: "http://pockets.readthedocs.org/")
 libraryLicense(name: "protobuf", version: "2.5.0", license: "New BSD", url: "http://code.google.com/p/protobuf/", licenseUrl: "https://github.com/google/protobuf/blob/master/LICENSE")
 libraryLicense(name: "proxy-vole", libraryName: "proxy-vole", version: "20131209", license: "New BSD License", url: "http://code.google.com/p/proxy-vole/", licenseUrl: "http://opensource.org/licenses/BSD-3-Clause")
-libraryLicense(name: "pty4j", libraryName: "pty4j", version: "0.6", license: "Eclipse Public License v1.0", url: "https://github.com/traff/pty4j")
+libraryLicense(name: "pty4j", libraryName: "pty4j", version: "0.7", license: "Eclipse Public License v1.0", url: "https://github.com/traff/pty4j")
 libraryLicense(name: "PureJavaComm", libraryName: "purejavacomm", version: "0.0.16", license: "BSD", url: "http://www.sparetimelabs.com/purejavacomm")
 libraryLicense(name: "ReflectASM", libraryName: "reflectasm-1.0.7.jar", version: "1.0.7", license: "BSD", url: "https://github.com/EsotericSoftware/reflectasm", licenseUrl: "http://opensource.org/licenses/BSD-3-Clause")
 libraryLicense(name: "Relax NG Object Model", libraryName: "rngom-20051226-patched.jar", license: "MIT", url: "http://java.net/projects/rngom/", licenseUrl: "http://www.opensource.org/licenses/mit-license.php")
index c7d91b0105fb6031e76eac312b044b58748552dc..1c1154f29a85d2971faff1fee0b1a3f37bb4f491 100644 (file)
@@ -2,4 +2,4 @@
 * cyglaunch.exe is a part of pty4j library licensed under Eclipse Public License and is linked with Cygwin™ according to Cygwin™ Open Source
   Licensing Exception (see https://cygwin.com/licensing.html)
 * purejavacomm - we use forked version that fixes JNA and YourKit Profiler incompatibility - https://github.com/traff/purejavacomm
-* libwinpty.dll and winpty-agent.exe - Windows PTY native implementation used by pty4j, we use forked version from https://github.com/traff/winpty
\ No newline at end of file
+* winpty.dll and winpty-agent.exe - Windows PTY native implementation used by pty4j - https://github.com/rprichard/winpty
\ No newline at end of file
diff --git a/lib/libpty/win/x86/libwinpty.dll b/lib/libpty/win/x86/libwinpty.dll
deleted file mode 100644 (file)
index 83221bc..0000000
Binary files a/lib/libpty/win/x86/libwinpty.dll and /dev/null differ
index 6c1fdd1295d701fc8dfc8f6fbd63e90ed77f4739..3abad80b84504bf9037cf98be77641fdf1bf508d 100644 (file)
Binary files a/lib/libpty/win/x86/winpty-agent.exe and b/lib/libpty/win/x86/winpty-agent.exe differ
diff --git a/lib/libpty/win/x86/winpty.dll b/lib/libpty/win/x86/winpty.dll
new file mode 100755 (executable)
index 0000000..f07b95a
Binary files /dev/null and b/lib/libpty/win/x86/winpty.dll differ
diff --git a/lib/libpty/win/x86_64/libwinpty.dll b/lib/libpty/win/x86_64/libwinpty.dll
deleted file mode 100644 (file)
index 519ca81..0000000
Binary files a/lib/libpty/win/x86_64/libwinpty.dll and /dev/null differ
index 8ebae382251d144ee9a8fcbc23b7306e16a7f826..e1963c4e3c85ba36bcc95a6e625cbbf5dadb6915 100644 (file)
Binary files a/lib/libpty/win/x86_64/winpty-agent.exe and b/lib/libpty/win/x86_64/winpty-agent.exe differ
diff --git a/lib/libpty/win/x86_64/winpty.dll b/lib/libpty/win/x86_64/winpty.dll
new file mode 100644 (file)
index 0000000..f9bdec0
Binary files /dev/null and b/lib/libpty/win/x86_64/winpty.dll differ
diff --git a/lib/libpty/win/xp/libwinpty.dll b/lib/libpty/win/xp/libwinpty.dll
deleted file mode 100755 (executable)
index 83221bc..0000000
Binary files a/lib/libpty/win/xp/libwinpty.dll and /dev/null differ
index 6c1fdd1295d701fc8dfc8f6fbd63e90ed77f4739..cc18efda8c6dcfba3648740612e9e4bdc3356707 100755 (executable)
Binary files a/lib/libpty/win/xp/winpty-agent.exe and b/lib/libpty/win/xp/winpty-agent.exe differ
diff --git a/lib/libpty/win/xp/winpty.dll b/lib/libpty/win/xp/winpty.dll
new file mode 100755 (executable)
index 0000000..bd40cd1
Binary files /dev/null and b/lib/libpty/win/xp/winpty.dll differ
similarity index 55%
rename from lib/pty4j-0.6.jar
rename to lib/pty4j-0.7.jar
index c49d42a0889db5be28ebd21f9f6e3db0a378c75b..0c3d34a793f4a93a0ae89a299c8661fa969e9b5e 100644 (file)
Binary files a/lib/pty4j-0.6.jar and b/lib/pty4j-0.7.jar differ
index 4bec9181fe1c7fe1698103e8ce259dd79783e257..88a651c5ceaa2ab2127684b6fcae87ad5b6edbaa 100644 (file)
@@ -57,7 +57,7 @@ oromatcher.jar
 picocontainer.jar
 protobuf-2.5.0.jar
 proxy-vole_20131209.jar
-pty4j-0.6.jar
+pty4j-0.7.jar
 purejavacomm.jar
 resolver.jar
 rhino-js-1_7R4.jar
similarity index 58%
rename from lib/src/pty4j-0.6-src.jar
rename to lib/src/pty4j-0.7-src.jar
index 93241bdada53cb36a77ae85428c316e7d9bdaaa2..cd45a7ab5c58b4dd2a3650cb094368274ee34290 100644 (file)
Binary files a/lib/src/pty4j-0.6-src.jar and b/lib/src/pty4j-0.7-src.jar differ
index a04b23a09084ca9091e6b4ea3874cd8427d574d8..c1354f4b3299911a209dba6cc7e8190462971966 100644 (file)
@@ -48,14 +48,6 @@ public class OSProcessHandler extends BaseOSProcessHandler {
     myHasErrorStream = !commandLine.isRedirectErrorStream();
     setHasPty(commandLine instanceof PtyCommandLine);
     myFilesToDelete = commandLine.getUserData(DELETE_FILES_ON_TERMINATION);
-    if (myHasPty && SystemInfo.isWindows) { // explicitly destroy pty on process termination, see IDEA-156065
-      addProcessListener(new ProcessAdapter() {
-        @Override
-        public void processTerminated(ProcessEvent event) {
-          getProcess().destroy();
-        }
-      });
-    }
   }
 
   /** @deprecated use {@link #OSProcessHandler(Process, String)} or any other ctor (to be removed in IDEA 17) */
similarity index 66%
rename from plugins/terminal/lib/jediterm-pty-2.1.jar
rename to plugins/terminal/lib/jediterm-pty-2.2.jar
index bef8585e0e76df493671c44e15b517cdb39af251..a1f211ba05dd43ac079ae861d5431e6592681425 100644 (file)
Binary files a/plugins/terminal/lib/jediterm-pty-2.1.jar and b/plugins/terminal/lib/jediterm-pty-2.2.jar differ
index 9f0fadd68752fb63d3c014371d8816d3a1366fd9..fe48ac065cd5e5e8f5af4cfa8506f6cd0f10a911 100644 (file)
@@ -175,6 +175,17 @@ public class JBTabbedTerminalWidget extends TabbedTerminalWidget implements Disp
       //nop
     }
 
+    @Override
+    public int indexOfComponent(Component component) {
+      for (int i = 0; i<myTabs.getTabCount(); i++) {
+        if (component.equals(myTabs.getTabAt(i).getComponent())) {
+          return i;
+        }
+      }
+      
+      return -1;
+    }
+
     @Override
     public int indexOfTabComponent(Component component) {
       return 0; //nop
index 68385590f6c788ebda83c43e03435f78d4c9c1a3..b173ddc2634311cec014375f8b6f9548494f7014 100644 (file)
@@ -13,7 +13,7 @@
     <orderEntry type="module-library">
       <library name="jediterm-pty">
         <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jediterm-pty-2.1.jar!/" />
+          <root url="jar://$MODULE_DIR$/lib/jediterm-pty-2.2.jar!/" />
         </CLASSES>
         <JAVADOC />
         <SOURCES />