greenstone.org greenstone wiki greenstone trac planet greenstone

Changeset 16400

Show
Ignore:
Timestamp:
2008-07-14 19:46:21 (3 months ago)
Author:
ak19
Message:

Checking canDoScheduling() before trying to do buildSchedule stuff

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • gli/trunk/src/org/greenstone/gatherer/gui/CreatePane.java

    r16148 r16400  
    6262import org.greenstone.gatherer.util.Utility; 
    6363 
     64import org.greenstone.gatherer.collection.CollectionManager; 
    6465 
    6566/** This class provides a GUI view showing some statistics on your current collection, and options for building it. As the collection is built this initial view is replaced with one showing progress bars and a message log of the creation process. This log can be later accessed via the options tree located in the center of the initial pane. This class is also responsible for creating the GShellProgressMonitors that are then attatched to external shell processes, and calling the methods in the CollectionManager for actually importing and building the collection. <br><BR> 
     
    364365            sargument_configuration_panel = options_pane.buildImport(null); 
    365366            sargument_configuration_panel = options_pane.buildBuild(sargument_configuration_panel); 
    366             sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel);  
     367            if(CollectionManager.canDoScheduling()) { 
     368                sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel);  
     369            } 
    367370        } 
    368371        else { 
     
    484487                sargument_configuration_panel = options_pane.buildImport(null); 
    485488                sargument_configuration_panel = options_pane.buildBuild(sargument_configuration_panel); 
    486                 sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel); 
     489                if(CollectionManager.canDoScheduling()) { 
     490                    sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel); 
     491                } 
    487492            } 
    488493            else { 
     
    626631            sargument_configuration_panel = options_pane.buildImport(null); 
    627632            sargument_configuration_panel = options_pane.buildBuild(sargument_configuration_panel); 
    628             sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel);  
     633            if(CollectionManager.canDoScheduling()) { 
     634                sargument_configuration_panel = options_pane.buildSchedule(sargument_configuration_panel);  
     635            } 
    629636            sargument_configuration_scroll = new JScrollPane(sargument_configuration_panel); 
    630637            sargument_configuration_scroll.setPreferredSize(ARGUMENT_SIZE); 
     
    982989                //target_pane.add(previous_pane, BorderLayout.CENTER); 
    983990            } 
    984             else if(node != null && node.equals(scheduling)) {  
     991            else if(node != null && node.equals(scheduling) && CollectionManager.canDoScheduling()) {  
    985992                build_button.setActionCommand(Dictionary.get("CreatePane.Schedule_Build"));  
    986993                build_button.setText(Dictionary.get("CreatePane.Schedule_Build"));