Changeset 8629
- Timestamp:
- 2004-11-23T14:55:29+13:00 (19 years ago)
- Location:
- trunk/gli/src/org/greenstone/gatherer
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/Gatherer.java
r8627 r8629 621 621 /** Loads the configuration file if one exists. Otherwise it creates a new one. Currently uses serialization. 622 622 * @param gsdl_path The path to the gsdl directory, gathered from the startup arguments, and presented as a <strong>String</strong>. 623 * @param library_url The path to the library executable, gathered from the startup arguments, and presented as a <strong>String</strong>.624 623 * @see org.greenstone.gatherer.Configuration 625 624 */ -
trunk/gli/src/org/greenstone/gatherer/GathererApplet.java
r8626 r8629 172 172 173 173 g_man = gatherer.init(size, go.gsdl_path, go.gsdl3_path, go.local_library_path, 174 go.library_url , go.debug, go.perl_path,174 go.library_url_string, go.debug, go.perl_path, 175 175 go.no_load, go.filename, go.site_name, 176 176 go.servlet_path, go.wget_version_str, go.wget_path); -
trunk/gli/src/org/greenstone/gatherer/GathererProg.java
r8626 r8629 91 91 GUIManager g_man 92 92 = gatherer.init(size, go.gsdl_path, go.gsdl3_path, go.local_library_path, 93 go.library_url , go.debug, go.perl_path,93 go.library_url_string, go.debug, go.perl_path, 94 94 go.no_load, go.filename, go.site_name, 95 95 go.servlet_path, go.wget_version_str, go.wget_path); -
trunk/gli/src/org/greenstone/gatherer/GetOpt.java
r8626 r8629 42 42 public String gsdl_path = null; 43 43 public String gsdl3_path = null; 44 public String library_url = null;44 public String library_url_string = null; 45 45 public String local_library_path = null; 46 46 public String perl_path = null; … … 185 185 // Manually specify the Greenstone library URL 186 186 else if (argument_name.equals(StaticStrings.LIBRARY_URL_ARGUMENT)) { 187 library_url = argument_value;187 library_url_string = argument_value; 188 188 } 189 189 // Parse the path to PERL. If not provided its assumes -
trunk/gli/src/org/greenstone/gatherer/LocalLibraryServer.java
r8627 r8629 59 59 static private void config(String command) 60 60 { 61 if (Configuration.library_url == null) { 62 System.err.println("Error: Trying to configure local library with null Configuration.library_url!"); 63 return; 64 } 65 61 66 try { 62 67 URL url = new URL(Configuration.library_url.toString() + command); -
trunk/gli/src/org/greenstone/gatherer/gui/CreatePane.java
r8627 r8629 384 384 tree.clearSelection(); 385 385 tree.setSelectionPath(path); 386 387 // Validate the preview button 388 if (Gatherer.c_man.built() && Configuration.library_url != null) { 389 preview_button.setEnabled(true); 390 simple_preview_button.setEnabled(true); 391 } 392 else { 393 preview_button.setEnabled(false); 394 simple_preview_button.setEnabled(false); 395 } 386 396 } 387 397 … … 542 552 } 543 553 tree.valueChanged(null); 544 545 // now do the preview stuff546 if (!Gatherer.c_man.built() || Configuration.library_url == null) {547 preview_button.setEnabled(false);548 simple_preview_button.setEnabled(false);549 } else {550 preview_button.setEnabled(true);551 simple_preview_button.setEnabled(true);552 }553 554 } 554 555 -
trunk/gli/src/org/greenstone/gatherer/gui/Preferences.java
r8627 r8629 191 191 library_path_label = new JLabel(); 192 192 library_path_label.setPreferredSize(LABEL_SIZE); 193 library_path_field = new JTextField(Configuration.library_url.toString()); 193 String library_url_string = ""; 194 if (Configuration.library_url != null) { 195 library_url_string = Configuration.library_url.toString(); 196 } 197 library_path_field = new JTextField(library_url_string); 194 198 library_path_field.setCaretPosition(0); 195 199 if (Gatherer.GS3) { … … 613 617 try { 614 618 Configuration.library_url = new URL(library_url_string); 615 // Configuration.setString("general.library_url", true, library_url_string);616 619 } 617 620 catch (MalformedURLException exception) { … … 619 622 } 620 623 } 624 Configuration.setString("general.library_url", true, library_url_string); 625 621 626 boolean site_changed = false; 622 627 if (Gatherer.GS3) {
Note:
See TracChangeset
for help on using the changeset viewer.