MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / check

Function check

tools/normalize/main.cpp:113–139  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111}
112
113void check(const QString &fileName)
114{
115 QFile file(fileName);
116 if (!file.open(QIODevice::ReadOnly)) {
117 qDebug("unable to open file: '%s' (%s)", fileName.toLocal8Bit().constData(), file.errorString().toLocal8Bit().constData());
118 return;
119 }
120 QStringList lines;
121 bool found = false;
122 while (true) {
123 QByteArray bline = file.readLine(16384);
124 if (bline.isEmpty())
125 break;
126 QString line = QString::fromLocal8Bit(bline);
127 Q_ASSERT_X(line.endsWith("\n"), "check()", fileName.toLocal8Bit().constData());
128 found |= checkSignature(fileName, line, "SLOT");
129 found |= checkSignature(fileName, line, "SIGNAL");
130 if (modify)
131 lines << line;
132 }
133 file.close();
134
135 if (found && modify) {
136 printf("Modifying file: '%s'\n", fileName.toLocal8Bit().constData());
137 writeChanges(fileName, lines);
138 }
139}
140
141void traverse(const QString &path)
142{

Callers 10

traverseFunction · 0.85
mainFunction · 0.85
setZoomFunction · 0.85
translateFunction · 0.85
zoomFunction · 0.85
zoomxFunction · 0.85
zoomyFunction · 0.85
fitFunction · 0.85
fillFunction · 0.85
setScreenSizeFunction · 0.85

Calls 5

checkSignatureFunction · 0.85
writeChangesFunction · 0.85
openMethod · 0.45
isEmptyMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected