MCPcopy Create free account
hub / github.com/QNapi/qnapi / setLanguage

Method setLanguage

libqnapi/src/subtitlelanguage.cpp:23–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21}
22
23void SubtitleLanguage::setLanguage(QString source) {
24 idx = -1;
25
26 if (source.length() == 2) {
27 idx = codes2l.indexOf(source.toLower());
28 } else if (source.length() == 3) {
29 idx = codes3l.indexOf(source.toLower());
30 } else {
31 idx = names.indexOf(source);
32 }
33}
34
35QString SubtitleLanguage::toTwoLetter() {
36 if (idx > -1) {

Callers 3

foreachFunction · 0.45
printHelpLanguagesMethod · 0.45
writeConfigMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected