| 120 | } |
| 121 | |
| 122 | void Plugin::attachHeaptrack() |
| 123 | { |
| 124 | #if HAVE_KSYSGUARD |
| 125 | const auto pid = KDevMI::askUserForProcessId(activeMainWindow()); |
| 126 | if (pid == 0) { |
| 127 | return; |
| 128 | } |
| 129 | |
| 130 | auto heaptrackJob = new Job(pid); |
| 131 | connect(heaptrackJob, &Job::finished, this, &Plugin::jobFinished); |
| 132 | core()->runController()->registerJob(heaptrackJob); |
| 133 | |
| 134 | m_launchAction->setEnabled(false); |
| 135 | #endif |
| 136 | } |
| 137 | |
| 138 | void Plugin::jobFinished(KJob* kjob) |
| 139 | { |
nothing calls this directly
no test coverage detected