MCPcopy Create free account
hub / github.com/chris2511/xca / switchLanguage

Method switchLanguage

widgets/XcaApplication.cpp:127–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

125}
126
127void XcaApplication::switchLanguage(QAction* a)
128{
129 QLocale lang = a->data().toLocale();
130 setupLanguage(lang);
131
132 QFile file(defaultlang());
133
134 if (lang == QLocale::system()) {
135 file.remove();
136 return;
137 }
138
139 if (file.open(QIODevice::WriteOnly)) {
140 file.write(lang.name().toUtf8());
141 }
142}
143
144bool XcaApplication::eventFilter(QObject *watched, QEvent *ev)
145{

Callers

nothing calls this directly

Calls 5

defaultlangFunction · 0.85
removeMethod · 0.80
openMethod · 0.80
dataMethod · 0.45
nameMethod · 0.45

Tested by

no test coverage detected