skin: synchronization of minimization
authorgiwoong.kim <giwoong.kim@samsung.com>
Thu, 14 Mar 2013 04:26:26 +0000 (13:26 +0900)
committergiwoong.kim <giwoong.kim@samsung.com>
Thu, 14 Mar 2013 04:26:26 +0000 (13:26 +0900)
synchronization of minimization between main window
and key window in general skin.

Signed-off-by: GiWoong Kim <giwoong.kim@samsung.com>
tizen/src/skin/client/src/org/tizen/emulator/skin/EmulatorSkin.java

index 686e207d2d057860aa87253094411bd3e45fa052..5ed3d9ae127640db4322afe192d8dc3d6cd3f9fd 100644 (file)
@@ -492,23 +492,34 @@ public class EmulatorSkin {
 
                        @Override
                        public void shellIconified(ShellEvent event) {
-                               /* do nothing */
-                       }
-
-                       @Override
-                       public void shellDeiconified(ShellEvent event) {
-                               logger.info("deiconified");
+                               logger.info("iconified");
 
+                               /* synchronization of minimization */
                                shell.getDisplay().asyncExec(new Runnable() {
                                        @Override
                                        public void run() {
                                                if (isKeyWindow == true && keyWindow != null) {
-                                                       if (keyWindow.getShell().getMinimized() == true) {
-                                                               keyWindow.getShell().setMinimized(false);
+                                                       if (keyWindow.getShell().getMinimized() == false) {
+                                                               keyWindow.getShell().setVisible(false);
+                                                               /* the tool style window is exposed
+                                                               when even it was minimized */
+                                                               keyWindow.getShell().setMinimized(true);
                                                        }
                                                }
                                        }
                                });
+                       }
+
+                       @Override
+                       public void shellDeiconified(ShellEvent event) {
+                               logger.info("deiconified");
+
+                               if (isKeyWindow == true && keyWindow != null) {
+                                       if (keyWindow.getShell().getMinimized() == true) {
+                                               keyWindow.getShell().setMinimized(false);
+                                               keyWindow.getShell().setVisible(true);
+                                       }
+                               }
 
                                DisplayStateData lcdStateData = new DisplayStateData(
                                                currentState.getCurrentScale(), currentState.getCurrentRotationId());