diff options
author | Lubomir I. Ivanov <neolit123@gmail.com> | 2012-11-01 23:27:49 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2012-11-05 09:27:46 -0800 |
commit | 27f1339079a67973c6d695ecfb9a1f873eeb4ae6 (patch) | |
tree | 2d850722439dabc8294d752ec339c7d0be186ec1 /subsurface.1 | |
parent | 37e3ade2e27b64f0696102e4ec421176ae430ffd (diff) | |
download | subsurface-27f1339079a67973c6d695ecfb9a1f873eeb4ae6.tar.gz |
Trim the device name in the download dialog, if necessary
On Windows, device names can end up being <drive-letter> (<drive-label>).
In such a case we are only interested in the <drive-letter> part, when
passing this value to libdivecomputer.
This patch provides a method to trim all text in parentheses and also
any leading and trailing whitespace.
An important addition is enabling back the user to enter a device
manually even it's absent in the combo box list. This device is
then stored and retrieved as the default device, but not stored
in the device list (dc_device_selector()).
As a side effect this change prevents the download dialog closing,
when a user-entered device is not one of the found devices via
subsurface_fill_device_list().
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface.1')
0 files changed, 0 insertions, 0 deletions