Changeset 9017
- Timestamp:
- 2005-02-14T11:07:52+13:00 (19 years ago)
- Location:
- trunk/gli/src/org/greenstone/gatherer
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/collection/CollectionManager.java
r8846 r9017 53 53 import org.greenstone.gatherer.cdm.CollectionMetaManager; 54 54 import org.greenstone.gatherer.cdm.CommandTokenizer; 55 import org.greenstone.gatherer.file.WorkspaceTree; // !!! Don't like this here56 55 import org.greenstone.gatherer.gui.LockFileDialog; 57 56 import org.greenstone.gatherer.gui.NewCollectionMetadataPrompt; … … 469 468 DebugStream.printStackTrace(error); 470 469 } 471 472 // Done, so refresh interface473 if (Gatherer.g_man != null) {474 // Return to some initial pane (Gather)475 Gatherer.g_man.returnToInitialPane();476 477 // Refresh the workspace tree to allow for the new collection478 Gatherer.g_man.refreshWorkspaceTree(WorkspaceTree.LIBRARY_CONTENTS_CHANGED);479 480 Gatherer.refresh(Gatherer.COLLECTION_OPENED);481 }482 470 } 483 471 … … 519 507 } 520 508 521 if (Utility.delete(collection_directory)) { 522 // Refresh the collections shown in the workspace tree 523 Gatherer.g_man.refreshWorkspaceTree(WorkspaceTree.LIBRARY_CONTENTS_CHANGED); 524 return true; 525 } 526 527 return false; 509 return Utility.delete(collection_directory); 528 510 } 529 511 -
trunk/gli/src/org/greenstone/gatherer/collection/DeleteCollectionPrompt.java
r8805 r9017 48 48 import org.greenstone.gatherer.Gatherer; 49 49 import org.greenstone.gatherer.LocalLibraryServer; 50 import org.greenstone.gatherer.file.WorkspaceTree; // !!! Don't like this here 50 51 import org.greenstone.gatherer.gui.GLIButton; 51 52 import org.greenstone.gatherer.gui.ModalDialog; … … 348 349 349 350 if (Gatherer.c_man.deleteCollection(collection.getShortName())) { 351 // Refresh the collections shown in the workspace tree 352 Gatherer.g_man.refreshWorkspaceTree(WorkspaceTree.LIBRARY_CONTENTS_CHANGED); 353 350 354 if (Gatherer.c_man.getCollection() != null && collection.getShortName().equals(Gatherer.c_man.getCollection().getName())) { 351 355 current_coll_deleted = true; -
trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java
r8992 r9017 57 57 import org.greenstone.gatherer.collection.ExportCollectionPrompt; 58 58 import org.greenstone.gatherer.file.FileOpenActionListener; 59 import org.greenstone.gatherer.file.WorkspaceTree; 59 60 import org.greenstone.gatherer.gui.metaaudit.MetaAuditFrame; 60 61 import org.greenstone.gatherer.gui.tree.DragTree; … … 695 696 ncm_prompt = null; 696 697 } 698 699 697 700 private class CreationTask 698 extends Thread { 701 extends Thread 702 { 699 703 private NewCollectionDetailsPrompt ncd_prompt = null; 700 704 private NewCollectionMetadataPrompt ncm_prompt = null; 701 public CreationTask(NewCollectionDetailsPrompt ncd_prompt, NewCollectionMetadataPrompt ncm_prompt) { 705 706 public CreationTask(NewCollectionDetailsPrompt ncd_prompt, NewCollectionMetadataPrompt ncm_prompt) 707 { 702 708 this.ncd_prompt = ncd_prompt; 703 709 this.ncm_prompt = ncm_prompt; 704 710 } 705 711 706 public void run() {707 ///ystem.err.println("Running CreationTask...");708 if (ncm_prompt == null) {712 public void run() 713 { 714 if (ncm_prompt == null) { 709 715 Gatherer.c_man.createCollection(ncd_prompt.getDescription(), Configuration.getEmail(), ncd_prompt.getName(), ncd_prompt.getTitle(), ncd_prompt.getBase(), null); 710 716 } 711 717 else { 712 718 Gatherer.c_man.createCollection(ncd_prompt.getDescription(), Configuration.getEmail(), ncd_prompt.getName(), ncd_prompt.getTitle(), null, ncm_prompt.getSets()); 713 }714 // Now that the collection specific settings are loaded we can set the 'view extracted metadata' property715 // do we want to have this in here???716 //Configuration.set("general.view_extracted_metadata", Configuration.COLLECTION_SPECIFIC, true); 719 ncm_prompt.dispose(); 720 ncm_prompt = null; 721 } 722 717 723 ncd_prompt.dispose(); 718 724 ncd_prompt = null; 719 if(ncm_prompt != null) { 720 ncm_prompt.dispose(); 721 ncm_prompt = null; 722 } 725 726 // Return to some initial pane (Gather) 727 returnToInitialPane(); 728 729 // Refresh the workspace tree to allow for the new collection 730 refreshWorkspaceTree(WorkspaceTree.LIBRARY_CONTENTS_CHANGED); 731 732 // Refresh the rest of the GLI 733 Gatherer.refresh(Gatherer.COLLECTION_OPENED); 723 734 } 724 735 }
Note:
See TracChangeset
for help on using the changeset viewer.