mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Group GncOptionMultChoiceValue::set_multiple with set_default_multiple.
Better readability.
This commit is contained in:
parent
27670a6e98
commit
be322a0d7c
@ -668,13 +668,6 @@ public:
|
||||
throw std::invalid_argument("Value not a valid choice.");
|
||||
|
||||
}
|
||||
void set_multiple(const GncMultichoiceOptionIndexVec& indexes)
|
||||
{
|
||||
if (validate(indexes))
|
||||
m_value = indexes;
|
||||
else
|
||||
throw std::invalid_argument("One of the supplied indexes was out of range.");
|
||||
}
|
||||
void set_default_value(const std::string& value)
|
||||
{
|
||||
auto index = find_key(value);
|
||||
@ -702,6 +695,13 @@ public:
|
||||
throw std::invalid_argument("Value not a valid choice.");
|
||||
|
||||
}
|
||||
void set_multiple(const GncMultichoiceOptionIndexVec& indexes)
|
||||
{
|
||||
if (validate(indexes))
|
||||
m_value = indexes;
|
||||
else
|
||||
throw std::invalid_argument("One of the supplied indexes was out of range.");
|
||||
}
|
||||
void set_default_multiple(const GncMultichoiceOptionIndexVec& indexes)
|
||||
{
|
||||
if (validate(indexes))
|
||||
|
Loading…
Reference in New Issue
Block a user