changeset 12113:70fe02b90e71

8162973: Better component components Reviewed-by: ssadetsky, prr, ahgross
author mcherkas
date Thu, 29 Sep 2016 16:06:49 +0300
parents 6060afebe7d0
children 920bb0a994d1 1b35fabb3d88
files src/windows/native/sun/windows/awt_Component.cpp
diffstat 1 files changed, 1 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/src/windows/native/sun/windows/awt_Component.cpp	Wed Sep 28 01:17:21 2016 +0300
+++ b/src/windows/native/sun/windows/awt_Component.cpp	Thu Sep 29 16:06:49 2016 +0300
@@ -98,7 +98,6 @@
 HWND AwtComponent::sm_focusOwner = NULL;
 HWND AwtComponent::sm_focusedWindow = NULL;
 BOOL AwtComponent::sm_bMenuLoop = FALSE;
-AwtComponent* AwtComponent::sm_getComponentCache = NULL;
 BOOL AwtComponent::sm_inSynthesizeFocus = FALSE;
 
 /************************************************************************/
@@ -272,10 +271,6 @@
      * handle.
      */
     DestroyHWnd();
-
-    if (sm_getComponentCache == this) {
-        sm_getComponentCache = NULL;
-    }
 }
 
 void AwtComponent::Dispose()
@@ -348,9 +343,6 @@
     if (hWnd == AwtToolkit::GetInstance().GetHWnd()) {
         return NULL;
     }
-    if (sm_getComponentCache && sm_getComponentCache->GetHWnd() == hWnd) {
-        return sm_getComponentCache;
-    }
 
     // check that it's an AWT component from the same toolkit as the caller
     if (::IsWindow(hWnd) &&
@@ -358,7 +350,7 @@
     {
         DASSERT(WmAwtIsComponent != 0);
         if (::SendMessage(hWnd, WmAwtIsComponent, 0, 0L)) {
-            return sm_getComponentCache = GetComponentImpl(hWnd);
+            return GetComponentImpl(hWnd);
         }
     }
     return NULL;