Changeset 7660 for trunk/gli/src
- Timestamp:
- 2004-06-29T14:59:10+12:00 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/gui/Preferences.java
r7639 r7660 70 70 private JButton apply_button; 71 71 private JButton cancel_button; 72 private JButton clear_cache_button;73 72 private JButton ok_button; 74 73 private JCheckBox show_file_size_checkbox; … … 296 295 Dictionary.registerTooltip(proxy_port_field, "Preferences.Connection.Proxy_Port_Tooltip"); 297 296 298 /** @todo - add to dictionary. Bet you're getting sick of these by now! */299 clear_cache_button = new GLIButton("Preferences.Connection.Clear_Cache");300 301 297 // Connection 302 298 use_proxy_checkbox.addActionListener(new UseProxyListener()); 303 clear_cache_button.addActionListener(new ClearCacheListener());304 299 if (Gatherer.GS3) { 305 300 site_combobox.addActionListener(new SiteComboboxListener()); … … 342 337 connection_pane.add(proxy_host_pane); 343 338 connection_pane.add(proxy_port_pane); 344 if(Gatherer.config.get(StaticStrings.WORKFLOW_MIRROR, true)) {345 connection_pane.add(clear_cache_button);346 }347 339 348 340 return connection_pane; … … 789 781 } 790 782 791 private class ClearCacheListener792 implements ActionListener {793 public void actionPerformed(ActionEvent event) {794 // Retrieve the cache folder and delete it.795 Utility.delete(Utility.getCacheDir());796 797 // ...and refresh the node in the workspace tree to show it's all gone798 Gatherer.g_man.refreshWorkspaceTree(WorkspaceTree.DOWNLOADED_FILES_CHANGED);799 }800 }801 802 783 private class DictionaryEntry 803 784 implements Comparable {
Note:
See TracChangeset
for help on using the changeset viewer.