diff options
author | Keith Packard <keithp@keithp.com> | 2013-06-11 16:31:20 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2013-06-11 16:39:24 -0700 |
commit | 6827d0a7c59d606ea05387465f1ad4d914babd49 (patch) | |
tree | 745b330b4fe8bee830d5d411468482c5ee26819c /altoslib/AltosConvert.java | |
parent | 15063cbb8f76bffea71575d295ca87b7ceca36d8 (diff) |
altosui: Use preferred units for main deployment height configuration
Show and accept values in the preferred units; create a separate list
of preferred values for each set of units
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'altoslib/AltosConvert.java')
-rw-r--r-- | altoslib/AltosConvert.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/altoslib/AltosConvert.java b/altoslib/AltosConvert.java index a42b36c4..8cd478e2 100644 --- a/altoslib/AltosConvert.java +++ b/altoslib/AltosConvert.java @@ -242,6 +242,10 @@ public class AltosConvert { return meters * (100 / (2.54 * 12)); } + public static double feet_to_meters(double feet) { + return feet * 12 * 2.54 / 100.0; + } + public static double meters_to_miles(double meters) { return meters_to_feet(meters) / 5280; } |