]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Java/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/FrameworkWizardUI.java
Make opening dialogs re-gain focus when user switch back to main UI from other window...
[mirror_edk2.git] / Tools / Java / Source / FrameworkWizard / src / org / tianocore / frameworkwizard / FrameworkWizardUI.java
index cc8a06534077793b6edaee4e49ef6993d2af4d0e..c3452d7b4c86741226cc0ce4dc464dd3c2205e57 100644 (file)
@@ -2784,31 +2784,31 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
             getJDesktopPanePackage().add(frmSpdHeader, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_LIBRARYCLASSDECLARATIONS:\r
-            SpdLibClassDecls frmSlcd = new SpdLibClassDecls(spd);\r
+            SpdLibClassDecls frmSlcd = new SpdLibClassDecls(spd, this);\r
             getJDesktopPanePackage().add(frmSlcd, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_MSAFILES:\r
-            SpdMsaFiles frmSmf = new SpdMsaFiles(spd);\r
+            SpdMsaFiles frmSmf = new SpdMsaFiles(spd, this);\r
             getJDesktopPanePackage().add(frmSmf, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_PACKAGEHEADERS:\r
-            SpdPackageHeaders frmSph = new SpdPackageHeaders(spd);\r
+            SpdPackageHeaders frmSph = new SpdPackageHeaders(spd, this);\r
             getJDesktopPanePackage().add(frmSph, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_GUIDDECLARATIONS:\r
-            SpdGuidDecls frmSgd = new SpdGuidDecls(spd);\r
+            SpdGuidDecls frmSgd = new SpdGuidDecls(spd, this);\r
             getJDesktopPanePackage().add(frmSgd, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_PROTOCOLDECLARATIONS:\r
-            SpdProtocolDecls frmSprod = new SpdProtocolDecls(spd);\r
+            SpdProtocolDecls frmSprod = new SpdProtocolDecls(spd, this);\r
             getJDesktopPanePackage().add(frmSprod, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_PPIDECLARATIONS:\r
-            SpdPpiDecls frmSppid = new SpdPpiDecls(spd);\r
+            SpdPpiDecls frmSppid = new SpdPpiDecls(spd, this);\r
             getJDesktopPanePackage().add(frmSppid, 1);\r
             break;\r
         case IDefaultMutableTreeNode.SPD_PCDDECLARATIONS:\r
-            SpdPcdDefs frmSpcdd = new SpdPcdDefs(spd);\r
+            SpdPcdDefs frmSpcdd = new SpdPcdDefs(spd, this);\r
             getJDesktopPanePackage().add(frmSpcdd, 1);\r
             break;\r
         }\r
@@ -3409,7 +3409,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
         int result = cso.showDialog();\r
         if (result == DataType.RETURN_TYPE_OK) {\r
             String strReturn = "Far Creation Completed!";\r
-            JOptionPane.showConfirmDialog(null, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.INFORMATION_MESSAGE);\r
         }\r
         cso.dispose();\r
@@ -3424,7 +3424,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
         int result = iso.showDialog();\r
         if (result == DataType.RETURN_TYPE_OK) {\r
             String strReturn = "<html>Far Installalation completed!<br>Refreshing the WORKSPACE!</html>";\r
-            JOptionPane.showConfirmDialog(null, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.INFORMATION_MESSAGE);\r
             this.closeAll();\r
             this.refresh();\r
@@ -3442,7 +3442,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
         int result = dso.showDialog();\r
         if (result == DataType.RETURN_TYPE_OK) {\r
             String strReturn = "<html>Far Deletion completed!<br>Refreshing the WORKSPACE!</html>";\r
-            JOptionPane.showConfirmDialog(null, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.INFORMATION_MESSAGE);\r
             this.closeAll();\r
             this.refresh();\r
@@ -3460,7 +3460,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
         int result = uso.showDialog();\r
         if (result == DataType.RETURN_TYPE_OK) {\r
             String strReturn = "<html>Far Update completed!<br>Refreshing the WORKSPACE!</html>";\r
-            JOptionPane.showConfirmDialog(null, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, strReturn, "Done", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.INFORMATION_MESSAGE);\r
             this.closeAll();\r
             this.refresh();\r
@@ -3707,7 +3707,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
                 return;\r
             }\r
 \r
-            JOptionPane.showConfirmDialog(null, "File is created", "Generate guids.xref", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, "File is created", "Generate guids.xref", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.INFORMATION_MESSAGE);\r
         }\r
     }\r
@@ -3723,7 +3723,7 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
         case Workspace.WORKSPACE_NOT_DEFINED:\r
             JOptionPane\r
                        .showConfirmDialog(\r
-                                          null,\r
+                                          this,\r
                                           "WORKSPACE Environment Variable Is Not Defined, Please select a valid WORKSPACE directory. "\r
                                                           + DataType.LINE_SEPARATOR\r
                                                           + DataType.LINE_SEPARATOR\r
@@ -3743,22 +3743,22 @@ public class FrameworkWizardUI extends IFrame implements KeyListener, MouseListe
                 break;\r
             }\r
         case Workspace.WORKSPACE_NOT_EXIST:\r
-            JOptionPane.showConfirmDialog(null, "Defined WORKSPACE Is Not Existed", "Error",\r
+            JOptionPane.showConfirmDialog(this, "Defined WORKSPACE Is Not Existed", "Error",\r
                                           JOptionPane.DEFAULT_OPTION, JOptionPane.ERROR_MESSAGE);\r
             this.dispose();\r
             System.exit(0);\r
         case Workspace.WORKSPACE_NOT_DIRECTORY:\r
-            JOptionPane.showConfirmDialog(null, "Defined WORKSPACE Is Not A Directory", "Error",\r
+            JOptionPane.showConfirmDialog(this, "Defined WORKSPACE Is Not A Directory", "Error",\r
                                           JOptionPane.DEFAULT_OPTION, JOptionPane.ERROR_MESSAGE);\r
             this.dispose();\r
             System.exit(0);\r
         case Workspace.WORKSPACE_NOT_VALID:\r
-            JOptionPane.showConfirmDialog(null, "WORKSPACE Environment Variable Is Not Valid", "Error",\r
+            JOptionPane.showConfirmDialog(this, "WORKSPACE Environment Variable Is Not Valid", "Error",\r
                                           JOptionPane.DEFAULT_OPTION, JOptionPane.ERROR_MESSAGE);\r
             this.dispose();\r
             System.exit(0);\r
         case Workspace.WORKSPACE_NO_TARGET_FILE:\r
-            JOptionPane.showConfirmDialog(null, "Target.txt File Is Not Existed", "Error", JOptionPane.DEFAULT_OPTION,\r
+            JOptionPane.showConfirmDialog(this, "Target.txt File Is Not Existed", "Error", JOptionPane.DEFAULT_OPTION,\r
                                           JOptionPane.ERROR_MESSAGE);\r
             this.dispose();\r
             System.exit(0);\r