Changeset 5131 in josm for trunk/src/org/openstreetmap/josm/actions
- Timestamp:
- 2012-03-29T22:37:42+02:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/ExtensionFileFilter.java
r4886 r5131 89 89 } 90 90 } 91 ); 91 ); 92 } 93 94 /** 95 * Updates the {@see AllFormatsImporter} that is contained in the importers list. If 96 * you do not use the importers variable directly, you don’t need to call this. 97 * 98 * Updating the AllFormatsImporter is required when plugins add new importers that 99 * support new file extensions. The old AllFormatsImporter doesn’t include the new 100 * extensions and thus will not display these files. 101 */ 102 public static void updateAllFormatsImporter() { 103 for(int i=0; i < importers.size(); i++) { 104 if(importers.get(i) instanceof AllFormatsImporter) { 105 importers.set(i, new AllFormatsImporter()); 106 } 107 } 92 108 } 93 109 … … 100 116 */ 101 117 public static List<ExtensionFileFilter> getImportExtensionFileFilters() { 118 updateAllFormatsImporter(); 102 119 LinkedList<ExtensionFileFilter> filters = new LinkedList<ExtensionFileFilter>(); 103 120 for (FileImporter importer : importers) { … … 199 216 if (name.endsWith("."+ext)) 200 217 return true; 201 218 return false; 202 219 } 203 220 … … 210 227 @Override public String getDescription() { 211 228 return description; 229 } 230 231 public String getExtensions() { 232 return extensions; 212 233 } 213 234
Note:
See TracChangeset
for help on using the changeset viewer.