MCPcopy Create free account
hub / github.com/MultiMC/Launcher / relPath

Method relPath

launcher/ui/dialogs/ExportInstanceDialog.cpp:146–155  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144 }
145
146 QString relPath(const QString &path) const
147 {
148 QString prefix = QDir().absoluteFilePath(m_instance->instanceRoot());
149 prefix += '/';
150 if (!path.startsWith(prefix))
151 {
152 return QString();
153 }
154 return path.mid(prefix.size());
155 }
156
157 bool setFilterState(QModelIndex index, Qt::CheckState state)
158 {

Callers

nothing calls this directly

Calls 4

QStringClass · 0.85
instanceRootMethod · 0.80
QDirClass · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected