8155083: On Windows, usage of USER_ATTENTION_WINDOW depends on state setting order
authorazvegint
Tue, 06 Sep 2016 13:03:00 +0300
changeset 41002 cb178d94b40e
parent 41001 a9586ec364da
child 41003 054df19db18c
8155083: On Windows, usage of USER_ATTENTION_WINDOW depends on state setting order Reviewed-by: serb, ssadetsky
jdk/src/java.desktop/share/classes/java/awt/Taskbar.java
jdk/src/java.desktop/share/classes/java/awt/peer/TaskbarPeer.java
jdk/src/java.desktop/windows/native/libawt/windows/awt_Taskbar.cpp
--- a/jdk/src/java.desktop/share/classes/java/awt/Taskbar.java	Fri Sep 02 21:42:27 2016 +0000
+++ b/jdk/src/java.desktop/share/classes/java/awt/Taskbar.java	Tue Sep 06 13:03:00 2016 +0300
@@ -273,9 +273,7 @@
     }
 
     /**
-     * Requests user attention to the specified window until it is activated.
-     *
-     * On an already active window requesting attention does nothing.
+     * Requests user attention to the specified window.
      *
      * @param w window
      * @throws SecurityException if a security manager exists and it denies the
--- a/jdk/src/java.desktop/share/classes/java/awt/peer/TaskbarPeer.java	Fri Sep 02 21:42:27 2016 +0000
+++ b/jdk/src/java.desktop/share/classes/java/awt/peer/TaskbarPeer.java	Tue Sep 06 13:03:00 2016 +0300
@@ -49,9 +49,7 @@
     default void requestUserAttention(boolean enabled, final boolean critical) {}
 
     /**
-     * Requests user attention to the specified window until it is activated.
-     *
-     * On an already active window requesting attention does nothing.
+     * Requests user attention to the specified window.
      *
      * @param w window
      */
--- a/jdk/src/java.desktop/windows/native/libawt/windows/awt_Taskbar.cpp	Fri Sep 02 21:42:27 2016 +0000
+++ b/jdk/src/java.desktop/windows/native/libawt/windows/awt_Taskbar.cpp	Tue Sep 06 13:03:00 2016 +0300
@@ -108,7 +108,7 @@
 JNIEXPORT void JNICALL Java_sun_awt_windows_WTaskbarPeer_flashWindow
   (JNIEnv *, jobject, jlong window)
 {
-    AwtWindow::FlashWindowEx((HWND) window, 3, 0, FLASHW_TIMERNOFG);
+    ::FlashWindow((HWND) window, TRUE);
 }
 
 /*