MCPcopy Create free account
hub / github.com/KDE/kdevelop / runScratch

Method runScratch

plugins/scratchpad/scratchpad.cpp:161–171  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

159}
160
161void Scratchpad::runScratch(const QModelIndex& index)
162{
163 qCDebug(PLUGIN_SCRATCHPAD) << "run" << index.data().toString();
164
165 auto command = index.data(RunCommandRole).toString();
166 command.replace(QLatin1String("$f"), index.data(FullPathRole).toString());
167 if (!command.isEmpty()) {
168 auto* job = new ScratchpadJob(command, index.data().toString(), this);
169 core()->runController()->registerJob(job);
170 }
171}
172
173void Scratchpad::removeScratch(const QModelIndex& index)
174{

Callers 1

runSelectedScratchMethod · 0.80

Calls 6

registerJobMethod · 0.80
runControllerMethod · 0.80
toStringMethod · 0.45
dataMethod · 0.45
replaceMethod · 0.45
isEmptyMethod · 0.45

Tested by

no test coverage detected