Commit Graph

5 Commits

Author SHA1 Message Date
John Ralls
d41292fddd Make set_selectable a GncOptionsGtkUIItem member function.
Callable from the option object with set_ui_item_selectable and from
Scheme as gnc-option-db-set-option-selectable-by-name.
2021-07-31 17:54:29 -07:00
John Ralls
01c0fe2364 Include what we use. 2021-07-31 17:54:28 -07:00
John Ralls
ac0e7063c7 Move the GncOptionUIType and dirty members to GncOptionUIUtem.
Even though it makes the class not pure virtual any more it is necessary
behavior common to all possible subclasses.
2021-07-31 17:54:28 -07:00
John Ralls
fce33799af Change GncOptionUIItem to be a pure virtual class instead of a templated one.
Simplifies the design because derived classes can have whatever save UI class
they need and implement the void(void) set_ui_item_from option and
set_option_from_ui_item with whatever functions are appropriate for
the UI class. No need for callbacks or std::function members.
2021-07-31 17:54:27 -07:00
John Ralls
99c2c5e439 GncOptionUIItem from the GncOptionVariant classes to GncOption.
Separating the UI from the data model. Note that the GncOptionVariant
classes still have a GncOptionUIType member to ensure that a
GncOptionUIItem of the right type is attached.
2021-07-10 17:29:15 -07:00