all repos — mgba @ 844cee07e8a16130d1f2df8886ab342df68923de

mGBA Game Boy Advance Emulator

Make sure GDB window is created in sync with GDB server state
Jeffrey Pfau jeffrey@endrift.com
Mon, 03 Feb 2014 03:44:39 -0800
commit

844cee07e8a16130d1f2df8886ab342df68923de

parent

8c53fbeb4f22b008a903fcacfac18c744d986cdc

1 files changed, 6 insertions(+), 3 deletions(-)

jump to
M src/platform/qt/GDBWindow.cppsrc/platform/qt/GDBWindow.cpp

@@ -39,10 +39,13 @@ m_bindAddressEdit->setMaxLength(15);

connect(m_bindAddressEdit, SIGNAL(textChanged(const QString&)), this, SLOT(bindAddressChanged(const QString&))); settingsGrid->addWidget(m_bindAddressEdit, 1, 1, Qt::AlignLeft); - m_startStopButton = new QPushButton(tr("Start")); - connect(m_startStopButton, SIGNAL(clicked()), m_gdbController, SLOT(listen())); - connect(m_startStopButton, SIGNAL(clicked()), this, SLOT(started())); + m_startStopButton = new QPushButton; mainSegment->addWidget(m_startStopButton); + if (m_gdbController->isAttached()) { + started(); + } else { + stopped(); + } } void GDBWindow::portChanged(const QString& portString) {