| 157 | |
| 158 | template<typename Func1, typename Func2, typename Func3> |
| 159 | void PreferencesDialog::MapSettingToCheckBox(QCheckBox *checkBox, Func1 getter, Func2 setter, Func3 notifier) const |
| 160 | { |
| 161 | // Get the value and set the checkbox state |
| 162 | checkBox->setChecked(std::bind(getter, settings)()); |
| 163 | |
| 164 | // Set up two way connection |
| 165 | connect(settings, notifier, checkBox, &QCheckBox::setChecked); |
| 166 | connect(checkBox, &QCheckBox::toggled, settings, setter); |
| 167 | } |
| 168 | |
| 169 | template<typename Func1, typename Func2, typename Func3> |
| 170 | void PreferencesDialog::MapSettingToGroupBox(QGroupBox *groupBox, Func1 getter, Func2 setter, Func3 notifier) const |
nothing calls this directly
no outgoing calls
no test coverage detected