MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / addSymbolFile

Method addSymbolFile

pcsx2-qt/Settings/DebugAnalysisSettingsWidget.cpp:376–404  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

374}
375
376void DebugAnalysisSettingsWidget::addSymbolFile()
377{
378 std::string path = Path::ToNativePath(QFileDialog::getOpenFileName(this, tr("Add Symbol File")).toStdString());
379 if (path.empty())
380 return;
381
382 std::string relative_path = Path::MakeRelative(path, EmuFolders::GameSettings);
383 if (!relative_path.starts_with(".."))
384 path = std::move(relative_path);
385
386 int row = m_symbol_file_model->rowCount();
387 if (!m_symbol_file_model->insertRow(row))
388 return;
389
390 QStandardItem* path_item = new QStandardItem();
391 path_item->setText(QString::fromStdString(path));
392 m_symbol_file_model->setItem(row, PATH_COLUMN, path_item);
393
394 QStandardItem* base_address_item = new QStandardItem();
395 base_address_item->setText("");
396 m_symbol_file_model->setItem(row, BASE_ADDRESS_COLUMN, base_address_item);
397
398 QStandardItem* condition_item = new QStandardItem();
399 condition_item->setText("");
400 m_symbol_file_model->setItem(row, CONDITION_COLUMN, condition_item);
401
402 saveSymbolFiles();
403 updateEnabledStates();
404}
405
406void DebugAnalysisSettingsWidget::removeSymbolFile()
407{

Callers

nothing calls this directly

Calls 3

starts_withMethod · 0.80
emptyMethod · 0.45
rowCountMethod · 0.45

Tested by

no test coverage detected