MCPcopy Create free account
hub / github.com/CE-Programming/CEmu / gotoMemAddrNoRaise

Method gotoMemAddrNoRaise

gui/qt/debugger.cpp:2008–2035  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2006}
2007
2008HexWidget *MainWindow::gotoMemAddrNoRaise(uint32_t address) {
2009 HexWidget *memWidget = m_memWidget;
2010 bool didGoto = false;
2011 if (memWidget == Q_NULLPTR && !ui->debugMemoryWidget->isVisible()) {
2012 memWidget = firstMemWidget();
2013 }
2014 if (memWidget == Q_NULLPTR) {
2015 for (HexWidget *edit : ui->debugMemoryWidget->findChildren<HexWidget*>()) {
2016 uint32_t offset = address - edit->getBase();
2017 if (offset < edit->getSize()) {
2018 edit->setOffset(offset);
2019 memWidget = edit;
2020 didGoto = true;
2021 break;
2022 }
2023 }
2024 if (!didGoto) {
2025 if (m_docksMemory.isEmpty() && m_uiEditMode) {
2026 addMemDock(randomString(20), 8, true);
2027 }
2028 memWidget = firstMemWidget();
2029 }
2030 }
2031 if (memWidget != Q_NULLPTR && !didGoto) {
2032 memGoto(memWidget, address);
2033 }
2034 return memWidget;
2035}
2036
2037QAction *MainWindow::gotoMemAction(QMenu *menu, bool vat) {
2038 QAction *gotoMem = menu->addAction(vat ? ACTION_GOTO_VAT_MEMORY_VIEW : ACTION_GOTO_MEMORY_VIEW);

Callers

nothing calls this directly

Calls 4

randomStringFunction · 0.85
getBaseMethod · 0.80
getSizeMethod · 0.80
setOffsetMethod · 0.80

Tested by

no test coverage detected