MCPcopy Create free account
hub / github.com/KDAB/GammaRay / saveTargetState

Method saveTargetState

ui/mainwindow.cpp:317–325  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

315}
316
317void MainWindow::saveTargetState(QSettings *settings) const
318{
319 // When closing/quitting the client main window, this is triggered but the connection is already closed
320 if (Endpoint::instance()->isConnected()) {
321 const QModelIndex toolIndex = ui->toolSelector->selectionModel()->selectedRows().value(0);
322 const QString toolId = toolIndex.data(ToolModelRole::ToolId).toString();
323 settings->setValue("selectedToolId", toolId);
324 }
325}
326
327void MainWindow::restoreTargetState(QSettings *settings)
328{

Callers

nothing calls this directly

Calls 5

isConnectedMethod · 0.45
valueMethod · 0.45
selectionModelMethod · 0.45
dataMethod · 0.45
setValueMethod · 0.45

Tested by

no test coverage detected