Imported Upstream version 18.3
Bas Couwenberg
8 years ago
0 | 0 | # Build script using external exif library |
1 | 1 | # Version number |
2 | PRUNENAME=gpsprune_18.2 | |
2 | PRUNENAME=gpsprune_18.3 | |
3 | 3 | # remove compile directory |
4 | 4 | rm -rf compile |
5 | 5 | # remove dist directory |
35 | 35 | public class GpsPrune |
36 | 36 | { |
37 | 37 | /** Version number of application, used in about screen and for version check */ |
38 | public static final String VERSION_NUMBER = "18.2"; | |
38 | public static final String VERSION_NUMBER = "18.3"; | |
39 | 39 | /** Build number, just used for about screen */ |
40 | public static final String BUILD_NUMBER = "336a"; | |
40 | public static final String BUILD_NUMBER = "336b"; | |
41 | 41 | /** Static reference to App object */ |
42 | 42 | private static App APP = null; |
43 | 43 | |
232 | 232 | try |
233 | 233 | { |
234 | 234 | ArrayList<Image> icons = new ArrayList<Image>(); |
235 | String[] resolutions = {"_16", "_20", "_32", "_64", "_128"}; | |
235 | String[] resolutions = {"_16", "_20", "_22", "_24", "_32", "_36", "_48", "_64", "_72", "_96", "_128"}; | |
236 | 236 | for (String r : resolutions) { |
237 | 237 | icons.add(IconManager.getImageIcon(IconManager.WINDOW_ICON + r + ".png").getImage()); |
238 | 238 | } |
254 | 254 | |
255 | 255 | // finish off and display frame |
256 | 256 | frame.pack(); |
257 | frame.setSize(650, 450); | |
257 | if (!setFrameBoundsFromConfig(frame)) | |
258 | { | |
259 | frame.setSize(650, 450); | |
260 | } | |
258 | 261 | frame.setVisible(true); |
259 | 262 | // Set position of map/profile splitter |
260 | 263 | midSplit.setDividerLocation(0.75); |
269 | 272 | APP.loadDataFiles(inDataFiles); |
270 | 273 | } |
271 | 274 | |
275 | ||
276 | /** | |
277 | * Set the frame bounds using the saved config setting | |
278 | * @param inFrame frame to set the bounds of | |
279 | * @return true on success | |
280 | */ | |
281 | private static boolean setFrameBoundsFromConfig(JFrame inFrame) | |
282 | { | |
283 | // Try to get bounds from config | |
284 | String bounds = Config.getConfigString(Config.KEY_WINDOW_BOUNDS); | |
285 | try | |
286 | { | |
287 | String[] boundValues = bounds.split("x"); | |
288 | if (boundValues.length == 4) | |
289 | { | |
290 | int[] elems = new int[4]; | |
291 | for (int i=0; i<4; i++) { | |
292 | elems[i] = Integer.parseInt(boundValues[i]); | |
293 | } | |
294 | // Make sure width and height aren't stupid | |
295 | elems[2] = Math.max(elems[2], 400); | |
296 | elems[3] = Math.max(elems[3], 300); | |
297 | inFrame.setBounds(elems[0], elems[1], elems[2], elems[3]); | |
298 | return true; | |
299 | } | |
300 | } | |
301 | catch (NullPointerException npe) {} // if no entry found in config | |
302 | catch (NumberFormatException nfe) {} // if string couldn't be parsed | |
303 | return false; | |
304 | } | |
305 | ||
306 | ||
272 | 307 | /** |
273 | 308 | * Try to guess whether it's a mistyped parameter or a mistyped filename |
274 | 309 | * @param inParam command line argument |
62 | 62 | public static final String KEY_MAPSOURCE_LIST = "prune.mapsourcelist"; |
63 | 63 | /** Key for show map flag */ |
64 | 64 | public static final String KEY_SHOW_MAP = "prune.showmap"; |
65 | /** Key for window position */ | |
66 | public static final String KEY_WINDOW_BOUNDS = "prune.windowbounds"; | |
65 | 67 | /** Key for path to disk cache */ |
66 | 68 | public static final String KEY_DISK_CACHE = "prune.diskcache"; |
67 | 69 | /** Key for working online flag */ |
0 | The source code of GpsPrune is copyright 2006-2015 activityworkshop.net | |
0 | The source code of GpsPrune is copyright 2006-2016 activityworkshop.net | |
1 | 1 | and is distributed under the terms of the Gnu GPL version 2. |
2 | 2 | |
3 | 3 | Portions of the package jpeg.drew (if included in this package) were taken |
3 | 3 | import java.awt.Component; |
4 | 4 | import java.awt.FlowLayout; |
5 | 5 | import java.awt.GridLayout; |
6 | import java.awt.Rectangle; | |
6 | 7 | import java.awt.event.ActionEvent; |
7 | 8 | import java.awt.event.ActionListener; |
8 | 9 | import java.io.File; |
157 | 158 | */ |
158 | 159 | private void saveConfig(File inSaveFile) |
159 | 160 | { |
161 | // Set current window position in config | |
162 | Rectangle currBounds = _app.getFrame().getBounds(); | |
163 | String windowBounds = "" + currBounds.x + "x" + currBounds.y + "x" | |
164 | + currBounds.width + "x" + currBounds.height; | |
165 | Config.setConfigString(Config.KEY_WINDOW_BOUNDS, windowBounds); | |
166 | ||
160 | 167 | // TODO: Check for null inSaveFile, then just call finish() ? |
161 | 168 | FileOutputStream outStream = null; |
162 | 169 | try |
Binary diff not shown
Binary diff not shown
Binary diff not shown
Binary diff not shown
Binary diff not shown
Binary diff not shown
367 | 367 | dialog.gpsies.activity.snowshoe=Raquette |
368 | 368 | dialog.gpsies.activity.sailing=Volle |
369 | 369 | dialog.gpsies.activity.skating=Skating |
370 | dialog.mapillary.nonefound=Aucun foto trouv\u00e9 | |
370 | 371 | dialog.wikipedia.column.name=Nom de l'article |
371 | 372 | dialog.wikipedia.column.distance=Distance |
372 | 373 | dialog.wikipedia.nonefound=Aucune points trouv\u00e9e |
374 | dialog.wikipedia.gallery=Galerie | |
375 | dialog.geocaching.nonefound=Aucun g\u00e9ocaches trouv\u00e9e | |
373 | 376 | dialog.correlate.notimestamps=Les points n'ont pas d'indication de temps, il n'est pas possible de les corr\u00e9ler. |
374 | 377 | dialog.correlate.nouncorrelatedphotos=Il n'y a pas de photos non-corr\u00e9l\u00e9es.\nVoulez-vous continuer ? |
375 | 378 | dialog.correlate.nouncorrelatedaudios=Il n'y a pas d'audios non-corr\u00e9l\u00e9s.\nVoulez-vous continuer ? |
519 | 522 | dialog.colourer.type.bygradient=Selon la pente |
520 | 523 | dialog.colourer.type.bydate=Selon la date |
521 | 524 | dialog.colourer.maxcolours=Nombre de couleurs maximum |
525 | dialog.colourer.start=Couleur au d\u00e9but | |
526 | dialog.colourer.end=Couleur \u00e0 la fin | |
522 | 527 | dialog.setlanguage.firstintro=Vous pouvez s\u00e9lectionner l'une des langues disponibles,<p> ou bien un fichier de langue \u00e0 utiliser. |
523 | 528 | dialog.setlanguage.secondintro=Vous devez sauvegarder vos param\u00e8tres puis<p>red\u00e9marrer GpsPrune pour changer de langue. |
524 | 529 | dialog.setlanguage.language=Langue |
571 | 576 | dialog.deletebydate.nodate=Sans horodatage |
572 | 577 | dialog.deletebydate.column.keep=Garder |
573 | 578 | dialog.deletebydate.column.delete=Supprimer |
579 | dialog.setaltitudetolerance.text.metres=Limite (m\u00e8tres) pour les petites diff\u00e9rences d'altitude | |
580 | dialog.setaltitudetolerance.text.feet=Limite (pieds) pour les petites diff\u00e9rences d'altitude | |
574 | 581 | dialog.autoplay.duration=Dur\u00e9e (sec) |
582 | dialog.autoplay.usetimestamps=Utiliser information de temps | |
583 | dialog.autoplay.rewind=Retour au d\u00e9but | |
575 | 584 | dialog.autoplay.pause=Pause |
576 | 585 | dialog.autoplay.play=Jouer |
577 | 586 | |
621 | 630 | # Tips |
622 | 631 | tip.title=Astuce |
623 | 632 | tip.useamapcache=By setting up a disk cache (Pr\u00e9f\u00e9rences -> Enregistrer les cartes sur le disque)\nyou can speed up the display and reduce network traffic. |
624 | tip.learntimeparams=The results will be more accurate if you use\nTrace -> Learn time estimation parameters\non your recorded tracks. | |
633 | tip.learntimeparams=The results will be more accurate if you use\nTrace -> Apprentissage de l'estimation\non your recorded tracks. | |
625 | 634 | tip.downloadsrtm=You can speed this up by calling\nEn ligne -> T\u00e9l\u00e9charger les donn\u00e9es SRTM\nto save the data in your map cache. |
626 | tip.usesrtmfor3d=This track doesn't have altitudes.\nYou can use the SRTM functions to get approximate\naltitudes for the 3d view. | |
627 | 635 | tip.manuallycorrelateone=En corr\u00e9lant manuellement au moins une photo, le d\u00e9calage de temps peut \u00eatre calcul\u00e9 pour vous. |
628 | 636 | |
629 | 637 | # Buttons |
0 | GpsPrune version 18.2 | |
0 | GpsPrune version 18.3 | |
1 | 1 | ===================== |
2 | 2 | |
3 | 3 | GpsPrune is an application for viewing, editing and managing coordinate data from GPS systems, |
4 | 4 | including format conversion, charting, 3d visualisation, audio and photo correlation, and online resource lookup. |
5 | 5 | Full details can be found at http://gpsprune.activityworkshop.net/ |
6 | 6 | |
7 | GpsPrune is copyright 2006-2015 activityworkshop.net and distributed under the terms of the Gnu GPL version 2. | |
7 | GpsPrune is copyright 2006-2016 activityworkshop.net and distributed under the terms of the Gnu GPL version 2. | |
8 | 8 | You may freely use the software, and may help others to freely use it too. For further information |
9 | 9 | on your rights and how they are protected, see the included license.txt file. |
10 | 10 | |
16 | 16 | ======= |
17 | 17 | |
18 | 18 | To run GpsPrune from the jar file, simply call it from a command prompt or shell: |
19 | java -jar gpsprune_18.2.jar | |
19 | java -jar gpsprune_18.3.jar | |
20 | 20 | |
21 | 21 | If the jar file is saved in a different directory, you will need to include the path. |
22 | 22 | Depending on your system settings, you may be able to click or double-click on the jar file |
24 | 24 | or other link can of course be made should you wish. |
25 | 25 | |
26 | 26 | To specify a language other than the default, use an additional parameter, eg: |
27 | java -jar gpsprune_18.2.jar --lang=DE | |
28 | ||
27 | java -jar gpsprune_18.3.jar --lang=DE | |
28 | ||
29 | ||
30 | New with version 18.3 | |
31 | ===================== | |
32 | The following fixes and additions were made since version 18.2: | |
33 | - Fix for saving track names and descriptions containing ampersands in xml formats (thanks, Joe!) | |
34 | - Additional window icon sizes (thanks, Sebastic!) | |
35 | - Remember window size | |
29 | 36 | |
30 | 37 | New with version 18.2 |
31 | 38 | ===================== |
346 | 346 | final String gpxHeader = getGpxHeaderString(inGpxCachers); |
347 | 347 | final boolean isVersion1_1 = (gpxHeader.toUpperCase().indexOf("GPX/1/1") > 0); |
348 | 348 | inWriter.write(gpxHeader); |
349 | // Name field | |
350 | String trackName = (inName != null && !inName.equals("")) ? inName : "GpsPruneTrack"; | |
351 | writeNameAndDescription(inWriter, inName, inDesc, isVersion1_1); | |
352 | ||
353 | int i = 0; | |
349 | // name and description | |
350 | String trackName = (inName != null && !inName.equals("")) ? XmlUtils.fixCdata(inName) : "GpsPruneTrack"; | |
351 | String desc = (inDesc != null && !inDesc.equals("")) ? XmlUtils.fixCdata(inDesc) : "Export from GpsPrune"; | |
352 | writeNameAndDescription(inWriter, trackName, desc, isVersion1_1); | |
353 | ||
354 | 354 | DataPoint point = null; |
355 | 355 | final boolean exportTrackpoints = inSaveFlags[0]; |
356 | 356 | final boolean exportWaypoints = inSaveFlags[1]; |
367 | 367 | // Loop over waypoints |
368 | 368 | final int numPoints = inInfo.getTrack().getNumPoints(); |
369 | 369 | int numSaved = 0; |
370 | for (i=0; i<numPoints; i++) | |
370 | for (int i=0; i<numPoints; i++) | |
371 | 371 | { |
372 | 372 | point = inInfo.getTrack().getPoint(i); |
373 | 373 | if (!exportSelection || (i>=selStart && i<=selEnd)) |
422 | 422 | private static void writeNameAndDescription(OutputStreamWriter inWriter, |
423 | 423 | String inName, String inDesc, boolean inIsVersion1_1) throws IOException |
424 | 424 | { |
425 | String desc = (inDesc != null && !inDesc.equals("")) ? inDesc : "Export from GpsPrune"; | |
426 | 425 | // Position of name and description fields needs to be different for GPX1.0 and GPX1.1 |
427 | 426 | if (inIsVersion1_1) |
428 | 427 | { |
438 | 437 | } |
439 | 438 | if (inIsVersion1_1) {inWriter.write('\t');} |
440 | 439 | inWriter.write("\t<desc>"); |
441 | inWriter.write(desc); | |
440 | inWriter.write(inDesc); | |
442 | 441 | inWriter.write("</desc>\n"); |
443 | 442 | if (inIsVersion1_1) |
444 | 443 | { |
482 | 482 | inWriter.write("<Folder>\n\t<name>"); |
483 | 483 | if (_descriptionField != null && _descriptionField.getText() != null && !_descriptionField.getText().equals("")) |
484 | 484 | { |
485 | inWriter.write(_descriptionField.getText()); | |
485 | inWriter.write(XmlUtils.fixCdata(_descriptionField.getText())); | |
486 | 486 | } |
487 | 487 | else { |
488 | 488 | inWriter.write("Export from GpsPrune"); |