Ignore:
Timestamp:
2019-03-25T18:13:17+13:00 (5 years ago)
Author:
ak19
Message:

Changes to reinstate SwingUtilities.invokeLater() calls added for GUI testing so that it will still work with the remote GS server. Note however that new Gatherer() calls Gatherer.init() does a lot of GUI stuff too depending on circumstances (such as requestGLIServerURL(), missingGSDL(), missingExec(), popupFedoraInfo(), initCollectDirectoryPath() which calls nonStandardCollectHomeMessage()). But Gatherer.init() is not yet wrapped in an invokeLater(), so this will conflict with GLI GUI testing.

File:
1 edited

Legend:

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

    r32695 r32923  
    672672        }
    673673
     674    }
     675
     676   
     677    /** Returns the correct version of the (local or remote) Greenstone server if init() has already been called. */
     678    public static int serverVersionNumber() {
     679        return GS3 ? 3 : 2;
     680    }
     681
     682    /** Returns "Server: version number" if init() has already been called. */
     683    public static String getServerVersionAsString() {
     684        return "Server: v" + serverVersionNumber();
     685    }
     686
     687    public void openGUI()
     688    {
     689
     690        // openGUI() is called on the EDT (graphical/swing thread)
     691        // remoteGS.downloadCollectionConfigurations() moved here as it calls remoteGS3.authenticateUser()
     692        // which displays a dialog to get user input and therefore belongs on the EDT.
    674693        // If using a remote Greenstone we need to download the collection configurations now
    675694        if (Gatherer.isGsdlRemote) {
     
    682701            }
    683702        }
    684     }
    685 
    686    
    687     /** Returns the correct version of the (local or remote) Greenstone server if init() has already been called. */
    688     public static int serverVersionNumber() {
    689         return GS3 ? 3 : 2;
    690     }
    691 
    692     /** Returns "Server: version number" if init() has already been called. */
    693     public static String getServerVersionAsString() {
    694         return "Server: v" + serverVersionNumber();
    695     }
    696 
    697     public void openGUI()
    698     {
     703       
    699704        // Size and place the frame on the screen
    700705        Rectangle bounds = Configuration.getBounds("general.bounds", true);
Note: See TracChangeset for help on using the changeset viewer.