Index: /main/trunk/gli/src/org/greenstone/gatherer/collection/CollectionManager.java
===================================================================
--- /main/trunk/gli/src/org/greenstone/gatherer/collection/CollectionManager.java	(revision 32711)
+++ /main/trunk/gli/src/org/greenstone/gatherer/collection/CollectionManager.java	(revision 32712)
@@ -60,4 +60,5 @@
 import org.greenstone.gatherer.gui.LockFileDialog;
 import org.greenstone.gatherer.gui.ModalProgressPopup;
+import org.greenstone.gatherer.gui.TestingPreparation;
 import org.greenstone.gatherer.gui.WarningDialog;
 import org.greenstone.gatherer.metadata.DocXMLFileManager;
@@ -551,4 +552,5 @@
 	// Create the collection on a separate thread so the progress bar updates correctly
 	(new CreateCollectionTask(description, email, name, title, base_collection_directory, metadata_sets, create_collection_progress_popup)).start();
+	//SwingUtilities.invokeLater(new CreateCollectionTask(description, email, name, title, base_collection_directory, metadata_sets, create_collection_progress_popup));
     }
 
@@ -1285,4 +1287,5 @@
 	// Load the collection on a separate thread so the progress bar updates correctly
 	(new LoadCollectionTask(collection_file_path, load_collection_progress_popup)).start();
+	//SwingUtilities.invokeLater(new LoadCollectionTask(collection_file_path, load_collection_progress_popup));
     }
 
@@ -1394,4 +1397,5 @@
 	if (lock_file.exists()) {
 	    LockFileDialog dialog = new LockFileDialog(Gatherer.g_man, collection_name, lock_file);
+	    TestingPreparation.setNamesRecursively(dialog);
 	    int choice = dialog.getChoice();
 	    dialog.dispose();
Index: /main/trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java
===================================================================
--- /main/trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java	(revision 32711)
+++ /main/trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java	(revision 32712)
@@ -183,5 +183,6 @@
 	}
 	else if (esrc == menu_bar.file_delete) {
-	    new DeleteCollectionTask().start();
+	    //new DeleteCollectionTask().start();
+	    SwingUtilities.invokeLater(new DeleteCollectionTask());
 	}
 	else if (esrc == menu_bar.file_cdimage) {
@@ -193,4 +194,5 @@
 	else if (esrc == menu_bar.file_exportas) {
 	    ExportAsPrompt eap = new ExportAsPrompt();
+	    TestingPreparation.setNamesRecursively(eap);
 	    eap.display();
 	    eap.destroy();
@@ -201,5 +203,6 @@
 	}
         else if (esrc == menu_bar.file_new) {
-	    new NewCollectionTask().start();
+	    //new NewCollectionTask().start();
+	    SwingUtilities.invokeLater(new NewCollectionTask());
 	}
 	else if (esrc == menu_bar.file_open) {
@@ -985,10 +988,16 @@
 
     private class NewCollectionTask
-	extends Thread
+	implements Runnable //extends Thread
     {
 	public void run()
 	{
 	    // Create the collection details prompt from new collection prompt
-	    NewCollectionDetailsPrompt ncd_prompt = new NewCollectionDetailsPrompt();
+	    NewCollectionDetailsPrompt ncd_prompt = new NewCollectionDetailsPrompt();	    
+	    //TestingPreparation.setNamesRecursively(ncd_prompt);
+	    // 1. names have to be set in NewCollectionDetailsPrompt, as it makes itself visible
+	    // and for testing we have to have run setName() on its components before the dialog goes visible
+	    // 2. For whatever reason, the NewCollectionDetailsPrompt dialog's own name is set
+	    // to "col" and it's not possible to change it at any point before or after
+	    // creating the dialog, and whether from inside or outside the dialog's own class
 
 	    // Create the new collection (if not cancelled) in a new thread.
@@ -1011,5 +1020,5 @@
 
     private class DeleteCollectionTask
-	extends Thread
+	implements Runnable //extends Thread
     {
 	public void run()
@@ -1017,4 +1026,5 @@
 	    // The rest is handled by the DeleteCollectionPrompt
 	    DeleteCollectionPrompt dc_prompt = new DeleteCollectionPrompt();
+	    TestingPreparation.setNamesRecursively(dc_prompt);
 	    if (dc_prompt.display()) {
 		//closeCurrentCollection();
@@ -1079,13 +1089,17 @@
     public void updateUI()
     {
-	JPanel pane = (JPanel) getContentPane();
-	pane.updateUI();
-	// Also update all of the tabs according to workflow.
-	workflowUpdate("Download", Configuration.get("workflow.download", false));
-	workflowUpdate("Gather", Configuration.get("workflow.gather", false));
-	workflowUpdate("Enrich", Configuration.get("workflow.enrich", false));
-	workflowUpdate("Design", Configuration.get("workflow.design", false));
-	workflowUpdate("Create", Configuration.get("workflow.create", false));
-	workflowUpdate("Format", Configuration.get("workflow.format", false));
+	SwingUtilities.invokeLater(new Runnable() {
+		public void run() {
+		    JPanel pane = (JPanel) getContentPane();
+		    pane.updateUI();
+		    // Also update all of the tabs according to workflow.
+		    workflowUpdate("Download", Configuration.get("workflow.download", false));
+		    workflowUpdate("Gather", Configuration.get("workflow.gather", false));
+		    workflowUpdate("Enrich", Configuration.get("workflow.enrich", false));
+		    workflowUpdate("Design", Configuration.get("workflow.design", false));
+		    workflowUpdate("Create", Configuration.get("workflow.create", false));
+		    workflowUpdate("Format", Configuration.get("workflow.format", false));
+		}
+	    });
     }
 
Index: /main/trunk/gli/src/org/greenstone/gatherer/gui/NewCollectionDetailsPrompt.java
===================================================================
--- /main/trunk/gli/src/org/greenstone/gatherer/gui/NewCollectionDetailsPrompt.java	(revision 32711)
+++ /main/trunk/gli/src/org/greenstone/gatherer/gui/NewCollectionDetailsPrompt.java	(revision 32712)
@@ -97,5 +97,5 @@
      */
     public NewCollectionDetailsPrompt() {
-	super(Gatherer.g_man, true);        
+	super(Gatherer.g_man, true);
 	this.cancelled = true;
         this.setComponentOrientation(Dictionary.getOrientation());
@@ -254,4 +254,7 @@
 	Dimension screen_size = Configuration.screen_size;
 	setLocation((screen_size.width - SIZE.width) / 2, (screen_size.height - SIZE.height) / 2);
+
+	TestingPreparation.setNamesRecursively(this);
+	
 	setVisible(true);
     }
Index: /main/trunk/gli/src/org/greenstone/gatherer/gui/SimpleResultDialog.java
===================================================================
--- /main/trunk/gli/src/org/greenstone/gatherer/gui/SimpleResultDialog.java	(revision 32711)
+++ /main/trunk/gli/src/org/greenstone/gatherer/gui/SimpleResultDialog.java	(revision 32712)
@@ -68,4 +68,5 @@
   
     setUpGUI(label, results);
+    TestingPreparation.setNamesRecursively(this);
   }
 
Index: /main/trunk/gli/src/org/greenstone/gatherer/gui/TestingPreparation.java
===================================================================
--- /main/trunk/gli/src/org/greenstone/gatherer/gui/TestingPreparation.java	(revision 32711)
+++ /main/trunk/gli/src/org/greenstone/gatherer/gui/TestingPreparation.java	(revision 32712)
@@ -6,5 +6,5 @@
 
 public class TestingPreparation {
-    public static boolean TEST_MODE = true; // TODO: set to true for debugging. Reset to false when committing to svn
+    public static boolean TEST_MODE = false; // TODO: set to true for debugging. Reset to false when committing to svn
     public static boolean DEBUGGING_TEST_MODE = true;
     
