changeset 1551:fb51d4974400

6851688: Hung up in applet application Reviewed-by: art, dcherepanov
author uta
date Fri, 31 Jul 2009 17:24:27 +0400
parents 2fb41bc4d896
children e6f6765a20f2
files src/windows/native/sun/windows/awt_Toolkit.cpp src/windows/native/sun/windows/awt_Toolkit.h
diffstat 2 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/windows/native/sun/windows/awt_Toolkit.cpp	Mon Jul 27 23:42:52 2009 -0700
+++ b/src/windows/native/sun/windows/awt_Toolkit.cpp	Fri Jul 31 17:24:27 2009 +0400
@@ -1596,18 +1596,18 @@
 }
 
 JNIEnv* AwtToolkit::m_env;
-HANDLE AwtToolkit::m_thread;
+DWORD AwtToolkit::m_threadId;
 
 void AwtToolkit::SetEnv(JNIEnv *env) {
     if (m_env != NULL) { // If already cashed (by means of embeddedInit() call).
         return;
     }
-    m_thread = GetCurrentThread();
+    m_threadId = GetCurrentThreadId();
     m_env = env;
 }
 
 JNIEnv* AwtToolkit::GetEnv() {
-    return (m_env == NULL || m_thread != GetCurrentThread()) ?
+    return (m_env == NULL || m_threadId != GetCurrentThreadId()) ?
         (JNIEnv*)JNU_GetEnv(jvm, JNI_VERSION_1_2) : m_env;
 }
 
--- a/src/windows/native/sun/windows/awt_Toolkit.h	Mon Jul 27 23:42:52 2009 -0700
+++ b/src/windows/native/sun/windows/awt_Toolkit.h	Fri Jul 31 17:24:27 2009 +0400
@@ -442,7 +442,7 @@
 
  private:
     static JNIEnv *m_env;
-    static HANDLE m_thread;
+    static DWORD m_threadId;
  public:
     static void SetEnv(JNIEnv *env);
     static JNIEnv* GetEnv();