ide: Debugger now has arrow buttons to change frame without dropping the list

git-svn-id: svn://ultimatepp.org/upp/trunk@13499 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2019-07-18 21:19:05 +00:00
parent 9bee07466a
commit f84d9bc4e3
6 changed files with 90 additions and 40 deletions

View file

@ -92,6 +92,8 @@ void Pdb::SetThread()
void Pdb::SetFrame()
{
int fi = ~framelist;
frame_up.Enable(fi > 0);
frame_down.Enable(fi < framelist.GetCount() - 1);
if(fi >= 0 && fi < frame.GetCount()) {
Frame& f = frame[fi];
current_frame = &f;
@ -131,6 +133,15 @@ void Pdb::SetFrame()
}
}
void Pdb::FrameUpDown(int dir)
{
int q = framelist.GetIndex() + dir;
if(q >= 0 && q < framelist.GetCount()) {
framelist.SetIndex(q);
SetFrame();
}
}
bool Pdb::SetBreakpoint(const String& filename, int line, const String& bp)
{
adr_t a = GetAddress(FilePos(filename, line));