MCPcopy Create free account
hub / github.com/dail8859/NotepadNext / MapSettingToGroupBox

Method MapSettingToGroupBox

src/dialogs/PreferencesDialog.cpp:170–178  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

168
169template<typename Func1, typename Func2, typename Func3>
170void PreferencesDialog::MapSettingToGroupBox(QGroupBox *groupBox, Func1 getter, Func2 setter, Func3 notifier) const
171{
172 // Get the value and set the checkbox state
173 groupBox->setChecked(std::bind(getter, settings)());
174
175 // Set up two way connection
176 connect(settings, notifier, groupBox, &QGroupBox::setChecked);
177 connect(groupBox, &QGroupBox::toggled, settings, setter);
178}
179
180void PreferencesDialog::populateTranslationComboBox()
181{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected