MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / browseMisraFile

Method browseMisraFile

gui/projectfiledialog.cpp:974–989  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

972}
973
974void ProjectFileDialog::browseMisraFile()
975{
976 const QString fileName = QFileDialog::getOpenFileName(this,
977 tr("Select MISRA rule texts file"),
978 QDir::homePath(),
979 tr("MISRA rule texts file (%1)").arg("*.txt"));
980 if (!fileName.isEmpty()) {
981 QSettings settings;
982 mUI->mEditMisraFile->setText(fileName);
983 settings.setValue(SETTINGS_MISRA_FILE, fileName);
984
985 mUI->mMisraC->setText("MISRA C 2012");
986 mUI->mMisraC->setEnabled(true);
987 updateAddonCheckBox(mUI->mMisraC, nullptr, getDataDir(), ADDON_MISRA);
988 }
989}

Callers

nothing calls this directly

Calls 5

updateAddonCheckBoxFunction · 0.85
getDataDirFunction · 0.85
isEmptyMethod · 0.80
setEnabledMethod · 0.80
setValueMethod · 0.45

Tested by

no test coverage detected