Ignore:
Timestamp:
2010-10-02T22:11:29+13:00 (14 years ago)
Author:
ak19
Message:

Again for ticket 152 (moveable collectdir). If the default GS collectdir is the one active in GLI (but all collections are closed) when exiting GLI, this default GS collectdir is not stored in config.xml (in the User Data location). Instead of the last opened collection or last open collectdir, an empty value is written out in the case of the default GS collectdir. This will allow other GS installations to open in their own collectdir. The benefits do not extend to if a collection in another GS' default collectdir was left open. In that case, the collection path is written out to the config.xml file, and the collectdir that a different GLI loads will be the old GLI's collect dir.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java

    r22686 r23015  
    510510    else {
    511511        // if there was no open collection, then write out the collect dir path for next time
    512         Configuration.setString("general.open_collection"+Configuration.gliPropertyNameSuffix(),
    513                     true, Gatherer.getCollectDirectoryPath()); // null
     512        // IF this is not the default collect directory
     513        if(Gatherer.getCollectDirectoryPath().equals(
     514                Gatherer.getDefaultGSCollectDirectoryPath(true))) {
     515            Configuration.setString("general.open_collection"+Configuration.gliPropertyNameSuffix(),
     516                    true, "");
     517        } else {
     518            Configuration.setString("general.open_collection"+Configuration.gliPropertyNameSuffix(),
     519                    true, Gatherer.getCollectDirectoryPath());
     520        }
    514521    }
    515522
Note: See TracChangeset for help on using the changeset viewer.