Changeset 5035


Ignore:
Timestamp:
2003-07-25T16:31:48+12:00 (21 years ago)
Author:
jmt12
Message:

Added extra method so that progress monitors can be told that the collection is in the middle of saving. Also added indeterminate state while determining document count.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/shell/GImportProgressMonitor.java

    r4686 r5035  
    6767    progress_bar.setMaximum(MAX);
    6868    progress_bar.setMinimum(MIN);
     69    progress_bar.setStringPainted(true);
    6970    progress_bar.setValue(MIN);
    7071    }
     
    120121      */
    121122    public void parse(String line_raw) {
     123    progress_bar.setString("");
    122124    String line = line_raw.toLowerCase();
    123125    if(line.indexOf(SENTINEL) != -1) {
     
    149151    }
    150152    }
     153
     154    public void saving() {
     155    progress_bar.setIndeterminate(true);
     156    progress_bar.setString(Gatherer.dictionary.get("SaveProgressDialog.Title", (String)null));
     157    }
     158
    151159    /** Since the creator of this process monitor is actually in the GUI, this class provides the simpliest way to send a cancel process message between the two.
    152160      * @param state The desired state of the stop flag as a <strong>boolean</strong>.
     
    157165    }
    158166    /** This method resets this monitor to the start, reseting the process parsing and progress bar.
    159       * TODO Everthing.
    160       */
     167     * TODO Everthing.
     168     */
    161169    public void start() {
     170    progress_bar.setIndeterminate(true);
     171    progress_bar.setString(Gatherer.dictionary.get("FileActions.Calculating_Size", (String)null));
     172    progress_bar.setIndeterminate(false);
    162173    num_dirs = Gatherer.c_man.getCollection().getFolderCount();
    163174    progress_bar.setValue(MIN);
     
    165176    }
    166177    /** This method indicates the process is complete.
    167       * TODO Everthing.
    168       */
     178     * TODO Everthing.
     179     */
    169180    public void stop() {
    170181    progress_bar.setIndeterminate(false);
Note: See TracChangeset for help on using the changeset viewer.