diff options
Diffstat (limited to 'desktop-widgets/command_edit.cpp')
-rw-r--r-- | desktop-widgets/command_edit.cpp | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/desktop-widgets/command_edit.cpp b/desktop-widgets/command_edit.cpp index 165bbbe90..8366db153 100644 --- a/desktop-widgets/command_edit.cpp +++ b/desktop-widgets/command_edit.cpp @@ -483,4 +483,27 @@ DiveField EditBuddies::fieldId() const return DiveField::BUDDY; } +// ***** DiveMaster ***** +QStringList EditDiveMaster::data(struct dive *d) const +{ + return stringToList(d->divemaster); +} + +void EditDiveMaster::set(struct dive *d, const QStringList &v) const +{ + QString text = v.join(", "); + free(d->divemaster); + d->divemaster = copy_qstring(text); +} + +QString EditDiveMaster::fieldName() const +{ + return tr("dive master"); +} + +DiveField EditDiveMaster::fieldId() const +{ + return DiveField::DIVEMASTER; +} + } // namespace Command |