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

Method openJsonEditor

launcher/Application.cpp:1282–1294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1280}
1281
1282bool Application::openJsonEditor(const QString &filename)
1283{
1284 const QString file = QDir::current().absoluteFilePath(filename);
1285 if (m_settings->get("JsonEditor").toString().isEmpty())
1286 {
1287 return DesktopServices::openUrl(QUrl::fromLocalFile(file));
1288 }
1289 else
1290 {
1291 //return DesktopServices::openFile(m_settings->get("JsonEditor").toString(), file);
1292 return DesktopServices::run(m_settings->get("JsonEditor").toString(), {file});
1293 }
1294}
1295
1296bool Application::launch(
1297 InstancePtr instance,

Callers 1

Calls 5

openUrlFunction · 0.85
runFunction · 0.85
isEmptyMethod · 0.80
toStringMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected