| 1272 | } |
| 1273 | |
| 1274 | bool Application::kill(InstancePtr instance) |
| 1275 | { |
| 1276 | if (!instance->isRunning()) |
| 1277 | { |
| 1278 | qWarning() << "Attempted to kill instance" << instance->id() << ", which isn't running."; |
| 1279 | return false; |
| 1280 | } |
| 1281 | auto & extras = m_instanceExtras[instance->id()]; |
| 1282 | // NOTE: copy of the shared pointer keeps it alive |
| 1283 | auto controller = extras.controller; |
| 1284 | if(controller) |
| 1285 | { |
| 1286 | return controller->abort(); |
| 1287 | } |
| 1288 | return true; |
| 1289 | } |
| 1290 | |
| 1291 | void Application::closeCurrentWindow() |
| 1292 | { |
no test coverage detected